[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 12/24] qdev-monitor: Propagate errors through set_pro
From: |
Markus Armbruster |
Subject: |
[Qemu-devel] [PULL 12/24] qdev-monitor: Propagate errors through set_property() |
Date: |
Mon, 22 Jun 2015 21:04:37 +0200 |
Signed-off-by: Markus Armbruster <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Andreas Färber <address@hidden>
---
qdev-monitor.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/qdev-monitor.c b/qdev-monitor.c
index 12d8f6b..c7b00e0 100644
--- a/qdev-monitor.c
+++ b/qdev-monitor.c
@@ -156,8 +156,7 @@ static int set_property(void *opaque, const char *name,
const char *value,
object_property_parse(obj, value, name, &err);
if (err != NULL) {
- qerror_report_err(err);
- error_free(err);
+ error_propagate(errp, err);
return -1;
}
return 0;
@@ -592,7 +591,8 @@ DeviceState *qdev_device_add(QemuOpts *opts)
}
/* set properties */
- if (qemu_opt_foreach(opts, set_property, dev, NULL)) {
+ if (qemu_opt_foreach(opts, set_property, dev, &err)) {
+ qerror_report_err(err);
object_unparent(OBJECT(dev));
object_unref(OBJECT(dev));
return NULL;
--
1.9.3
- [Qemu-devel] [PULL 00/24] Monitor patches, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 03/24] monitor: remove debug prints, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 05/24] monitor: Point to "help" command on syntax error, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 06/24] monitor: Fix failure path for "S" argument, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 12/24] qdev-monitor: Propagate errors through set_property(),
Markus Armbruster <=
- [Qemu-devel] [PULL 04/24] monitor: cleanup parsing of cmd name and cmd arguments, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 10/24] qdev-monitor: Fix check for full bus, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 09/24] qdev-monitor: Stop error avalanche in qbus_find_recursive(), Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 13/24] qdev-monitor: Propagate errors through qdev_device_add(), Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 15/24] vl: Avoid qerror_report() outside QMP command handlers, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 11/24] qdev-monitor: Convert qbus_find() to Error, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 01/24] qobject: Use 'bool' for qbool, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 02/24] qobject: Use 'bool' inside qdict, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 16/24] vl: Use error_report() for --display errors, Markus Armbruster, 2015/06/22
- [Qemu-devel] [PULL 17/24] qerror: Eliminate QERR_DEVICE_NOT_FOUND, Markus Armbruster, 2015/06/22