diff options
Diffstat (limited to 'hw/core')
-rw-r--r-- | hw/core/qdev.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/hw/core/qdev.c b/hw/core/qdev.c index 56daa7b456..ae3b006f39 100644 --- a/hw/core/qdev.c +++ b/hw/core/qdev.c @@ -398,8 +398,7 @@ bool qdev_realize(DeviceState *dev, BusState *bus, Error **errp) assert(!DEVICE_GET_CLASS(dev)->bus_type); } - object_property_set_bool(OBJECT(dev), "realized", true, &err); - if (err) { + if (!object_property_set_bool(OBJECT(dev), "realized", true, &err)) { error_propagate(errp, err); } return !err; |