aboutsummaryrefslogtreecommitdiff
path: root/qdev-monitor.c
diff options
context:
space:
mode:
Diffstat (limited to 'qdev-monitor.c')
-rw-r--r--qdev-monitor.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/qdev-monitor.c b/qdev-monitor.c
index cefd21b8e6..cbcbbb5d50 100644
--- a/qdev-monitor.c
+++ b/qdev-monitor.c
@@ -802,9 +802,8 @@ void qmp_device_add(QDict *qdict, QObject **ret_data, Error **errp)
QemuOpts *opts;
DeviceState *dev;
- opts = qemu_opts_from_qdict(qemu_find_opts("device"), qdict, &local_err);
- if (local_err) {
- error_propagate(errp, local_err);
+ opts = qemu_opts_from_qdict(qemu_find_opts("device"), qdict, errp);
+ if (!opts) {
return;
}
if (!monitor_cur_is_qmp() && qdev_device_help(opts)) {