aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbalrog <balrog@c046a42c-6fe2-441c-8c8c-71466251a162>2008-12-01 01:48:36 +0000
committerbalrog <balrog@c046a42c-6fe2-441c-8c8c-71466251a162>2008-12-01 01:48:36 +0000
commitd0513623aee6bca7b6458a12fc652ac028f03753 (patch)
treefbf8cb93bc96c80362b97d39ac6ef5116160a1c8
parent137519ce2e269915de0f67a13ac32b67605cad72 (diff)
Don't try to select on an invalid VNC socket when init fails.
Otherwise we get a segfault. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5840 c046a42c-6fe2-441c-8c8c-71466251a162
-rw-r--r--vnc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/vnc.c b/vnc.c
index f663b385d1..1d9c113539 100644
--- a/vnc.c
+++ b/vnc.c
@@ -2419,6 +2419,7 @@ int vnc_display_open(DisplayState *ds, const char *display)
}
if (-1 == vs->lsock) {
free(dpy);
+ return -1;
} else {
free(vs->display);
vs->display = dpy;