Skip to contentSkip to conversation

Fix regression in option parsing

PATCH New Anthony Liguori 1 participant 1 message Jan 27, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix regression in option parsing

Commit ec229bbe7 broke invocation without a specific -hda. IOW, qemu foo.img. The lack of an optind update caused an infinite loop.

---
 vl.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
vl.c +1 -0
index 1cd355c..6f1e1ab 100644
@@ -4819,6 +4819,7 @@ int main(int argc, char **argv, char **envp)
     while (optind < argc) {
         if (argv[optind][0] != '-') {
             /* disk image */
+            optind++;
             continue;
         } else {
             const QEMUOption *popt;
Signature · 1 line
1.6.5.2