aboutsummaryrefslogtreecommitdiff
path: root/hw/core/qdev.c
diff options
context:
space:
mode:
authorAndreas Färber <afaerber@suse.de>2013-05-01 16:10:24 +0200
committerAndreas Färber <afaerber@suse.de>2013-05-06 19:40:44 +0200
commitb1fe9bcbceb6fb9d800f735da37aa79ac4552c6e (patch)
tree228b470d02bea1a254336d5a7fd1f82e3dd93457 /hw/core/qdev.c
parent7e5292b553c9ec27e0816abdcb717f87aa6b6a8d (diff)
downloadqemu-b1fe9bcbceb6fb9d800f735da37aa79ac4552c6e.zip
qemu-b1fe9bcbceb6fb9d800f735da37aa79ac4552c6e.tar.gz
qemu-b1fe9bcbceb6fb9d800f735da37aa79ac4552c6e.tar.bz2
qdev: Let qdev_prop_parse() pass through Error
Move error reporting to callers. Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'hw/core/qdev.c')
-rw-r--r--hw/core/qdev.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/hw/core/qdev.c b/hw/core/qdev.c
index 069ac90..6985ad8 100644
--- a/hw/core/qdev.c
+++ b/hw/core/qdev.c
@@ -752,7 +752,12 @@ static void device_initfn(Object *obj)
}
class = object_class_get_parent(class);
} while (class != object_class_by_name(TYPE_DEVICE));
- qdev_prop_set_globals(dev);
+ qdev_prop_set_globals(dev, &err);
+ if (err != NULL) {
+ qerror_report_err(err);
+ error_free(err);
+ exit(1);
+ }
object_property_add_link(OBJECT(dev), "parent_bus", TYPE_BUS,
(Object **)&dev->parent_bus, &err);