]> git.proxmox.com Git - mirror_qemu.git/commit
softmmu/vl: Clean up global variable shadowing
authorPhilippe Mathieu-Daudé <philmd@linaro.org>
Wed, 4 Oct 2023 12:00:17 +0000 (14:00 +0200)
committerMarkus Armbruster <armbru@redhat.com>
Fri, 6 Oct 2023 11:27:48 +0000 (13:27 +0200)
commit48176a1d287179ea4e85122e1bc803f329773141
tree6120d17659c405b39ed897f4dfd1395515f0761b
parenta60e5736eb8d8b624739dd4e94b9faf07fdbbbe0
softmmu/vl: Clean up global variable shadowing

Fix:

  softmmu/vl.c:1069:44: error: declaration shadows a variable in the global scope [-Werror,-Wshadow]
  static void parse_display_qapi(const char *optarg)
                                             ^
  softmmu/vl.c:1224:39: error: declaration shadows a variable in the global scope [-Werror,-Wshadow]
  static void monitor_parse(const char *optarg, const char *mode, bool pretty)
                                        ^
  softmmu/vl.c:1634:17: error: declaration shadows a variable in the global scope [-Werror,-Wshadow]
      const char *optarg = qdict_get_try_str(qdict, "type");
                  ^
  softmmu/vl.c:1784:45: error: declaration shadows a variable in the global scope [-Werror,-Wshadow]
  static void object_option_parse(const char *optarg)
                                              ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/getopt.h:77:14: note: previous declaration is here
  extern char *optarg;                    /* getopt(3) external variables */
               ^

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20231004120019.93101-15-philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
[Tweak two parameter names]
Signed-off-by: Markus Armbruster <armbru@redhat.com>
softmmu/vl.c