[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 2/2] object_add not registering option
From: |
Eduardo Otubo |
Subject: |
[Qemu-devel] [PATCH 2/2] object_add not registering option |
Date: |
Wed, 15 Feb 2017 11:14:27 +0100 |
object_add (hmp command) wasn't registering its object in the internal
list of options, hence, not showing when using `writeconfig' command.
Steps to reproduce:
(qemu) object_add memory-backend-ram,id=mem1,size=1G
(qemu) device_add pc-dimm,id=dimm1,memdev=mem1
(qemu) writeconfig qemu.conf
When done before this patch, `writeconfig' would not output the mem1
object to the config file. After this patch the output is as follows:
[object "mem1"]
qom-type = "memory-backend-ram"
size = "1G"
Signed-off-by: Eduardo Otubo <address@hidden>
---
hmp.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/hmp.c b/hmp.c
index 4f2b8a10d2..36ae478482 100644
--- a/hmp.c
+++ b/hmp.c
@@ -1818,7 +1818,6 @@ void hmp_object_add(Monitor *mon, const QDict *qdict)
}
obj = user_creatable_add_opts(opts, &err);
- qemu_opts_del(opts);
if (err) {
hmp_handle_error(mon, &err);
--
2.11.0