---
 hw/qdev.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/hw/qdev.c b/hw/qdev.c
index 1102efd..4004860 100644
--- a/hw/qdev.c
+++ b/hw/qdev.c
@@ -1228,7 +1228,7 @@ void qdev_property_add_child(DeviceState *dev, const char 
*name,
     qdev_property_add(dev, name, type, qdev_get_child_property,
                       NULL, NULL, child, errp);
 
-    qdev_ref(dev);
+    qdev_ref(child);
     g_assert(child->parent == NULL);
     child->parent = dev;
 
-- 
1.7.4.1


Reply via email to