summaryrefslogtreecommitdiff
path: root/vl.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2011-03-23 03:40:57 +0000
committerAnthony Liguori <aliguori@us.ibm.com>2011-03-25 07:28:09 -0500
commit05175535a3b6c78186ec3538bcd1b01f30ba571e (patch)
tree2fe3f3aa2c596deb575a78984e86d60bfb6185a9 /vl.c
parent56d7a964a5664d3778a0b7a369a5f350d0fe099f (diff)
downloadqemu-05175535a3b6c78186ec3538bcd1b01f30ba571e.zip
vl.c: Fix compilation failure if CONFIG_SDL isn't defined
Fix a compilation failure if CONFIG_SDL isn't defined (gcc complained that the label 'invalid_display' wasn't used). Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'vl.c')
-rw-r--r--vl.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/vl.c b/vl.c
index dbb927dff6..c387f2b1ff 100644
--- a/vl.c
+++ b/vl.c
@@ -1575,7 +1575,7 @@ static DisplayType select_display(const char *p)
} else if (strstart(opts, "off", &nextopt)) {
no_frame = 1;
} else {
- goto invalid_display;
+ goto invalid_sdl_args;
}
} else if (strstart(opts, ",alt_grab=", &nextopt)) {
opts = nextopt;
@@ -1584,7 +1584,7 @@ static DisplayType select_display(const char *p)
} else if (strstart(opts, "off", &nextopt)) {
alt_grab = 0;
} else {
- goto invalid_display;
+ goto invalid_sdl_args;
}
} else if (strstart(opts, ",ctrl_grab=", &nextopt)) {
opts = nextopt;
@@ -1593,7 +1593,7 @@ static DisplayType select_display(const char *p)
} else if (strstart(opts, "off", &nextopt)) {
ctrl_grab = 0;
} else {
- goto invalid_display;
+ goto invalid_sdl_args;
}
} else if (strstart(opts, ",window_close=", &nextopt)) {
opts = nextopt;
@@ -1602,10 +1602,12 @@ static DisplayType select_display(const char *p)
} else if (strstart(opts, "off", &nextopt)) {
no_quit = 1;
} else {
- goto invalid_display;
+ goto invalid_sdl_args;
}
} else {
- goto invalid_display;
+ invalid_sdl_args:
+ fprintf(stderr, "Invalid SDL option string: %s\n", p);
+ exit(1);
}
opts = nextopt;
}
@@ -1642,7 +1644,6 @@ static DisplayType select_display(const char *p)
} else if (strstart(p, "none", &opts)) {
display = DT_NONE;
} else {
- invalid_display:
fprintf(stderr, "Unknown display type: %s\n", p);
exit(1);
}