aboutsummaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorDr. David Alan Gilbert <dgilbert@redhat.com>2017-10-05 20:07:25 +0100
committerMarkus Armbruster <armbru@redhat.com>2017-12-20 09:11:50 +0100
commitda78e382dddc499882120590ae0ac834881a96b8 (patch)
tree22423ee09c67719a6befd3e3a52651e84cbb713c /util
parent7ad9270ee21fdf0262a44ebf7e280c6a85022ced (diff)
option: Remove shadowing opt decl from qemu_opt_print()
opt was declared as a separate local inside the last loop, shadowing the local at the top of the function. Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Message-Id: <20171005190725.18712-1-dgilbert@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com>
Diffstat (limited to 'util')
-rw-r--r--util/qemu-option.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/qemu-option.c b/util/qemu-option.c
index 9b1dc8093b..877c5b4d67 100644
--- a/util/qemu-option.c
+++ b/util/qemu-option.c
@@ -766,7 +766,7 @@ void qemu_opts_print(QemuOpts *opts, const char *separator)
}
for (; desc && desc->name; desc++) {
const char *value;
- QemuOpt *opt = qemu_opt_find(opts, desc->name);
+ opt = qemu_opt_find(opts, desc->name);
value = opt ? opt->str : desc->def_value_str;
if (!value) {