aboutsummaryrefslogtreecommitdiff
path: root/util/qemu-config.c
diff options
context:
space:
mode:
Diffstat (limited to 'util/qemu-config.c')
-rw-r--r--util/qemu-config.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/util/qemu-config.c b/util/qemu-config.c
index 772f5a219e..c0d0e9b8ef 100644
--- a/util/qemu-config.c
+++ b/util/qemu-config.c
@@ -493,9 +493,8 @@ static void config_parse_qdict_section(QDict *options, QemuOptsList *opts,
goto out;
}
- subopts = qemu_opts_create(opts, NULL, 0, &local_err);
- if (local_err) {
- error_propagate(errp, local_err);
+ subopts = qemu_opts_create(opts, NULL, 0, errp);
+ if (!subopts) {
goto out;
}
@@ -538,10 +537,9 @@ static void config_parse_qdict_section(QDict *options, QemuOptsList *opts,
}
opt_name = g_strdup_printf("%s.%u", opts->name, i++);
- subopts = qemu_opts_create(opts, opt_name, 1, &local_err);
+ subopts = qemu_opts_create(opts, opt_name, 1, errp);
g_free(opt_name);
- if (local_err) {
- error_propagate(errp, local_err);
+ if (!subopts) {
goto out;
}