aboutsummaryrefslogtreecommitdiff
path: root/hw/usb-serial.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2010-01-15 12:56:41 +0100
committerAnthony Liguori <aliguori@us.ibm.com>2010-01-19 16:31:04 -0600
commitbeb6f0de7aa19ce62fdd21a876b8c171ac7fde2e (patch)
tree8955992d29c37fd607dd79006d8d9737c83a8dc6 /hw/usb-serial.c
parent0d2ed46af43365fd713532c5eb9450380635b694 (diff)
downloadqemu-beb6f0de7aa19ce62fdd21a876b8c171ac7fde2e.zip
qemu-beb6f0de7aa19ce62fdd21a876b8c171ac7fde2e.tar.gz
qemu-beb6f0de7aa19ce62fdd21a876b8c171ac7fde2e.tar.bz2
Fix QEMU_WARN_UNUSED_RESULT
Since commit 747bbdf7 QEMU_WARN_UNUSED_RESULT is never defined as it is conditional on a define from config-host.h which is included only later. Include that file earlier to get the warnings back. Reactivating it unfortunately leads to some warnings about unused qdev_init results. These calls are changed to qdev_init_nofail to avoid build failures. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/usb-serial.c')
-rw-r--r--hw/usb-serial.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/usb-serial.c b/hw/usb-serial.c
index 2775cf0..37293ea 100644
--- a/hw/usb-serial.c
+++ b/hw/usb-serial.c
@@ -583,7 +583,7 @@ static USBDevice *usb_serial_init(const char *filename)
qdev_prop_set_uint16(&dev->qdev, "vendorid", vendorid);
if (productid)
qdev_prop_set_uint16(&dev->qdev, "productid", productid);
- qdev_init(&dev->qdev);
+ qdev_init_nofail(&dev->qdev);
return dev;
}
@@ -599,7 +599,7 @@ static USBDevice *usb_braille_init(const char *unused)
dev = usb_create(NULL /* FIXME */, "usb-braille");
qdev_prop_set_chr(&dev->qdev, "chardev", cdrv);
- qdev_init(&dev->qdev);
+ qdev_init_nofail(&dev->qdev);
return dev;
}