From 52c18be9e99dabe295321153fda7fce9f76647ac Mon Sep 17 00:00:00 2001 From: Zachary Amsden Date: Thu, 30 Jul 2009 00:15:01 -1000 Subject: [PATCH] When using stdio monitor and VNC display, one can set or clear a VNC password; this should set or turn off VNC authentication as well. Signed-off-by: Zachary Amsden Signed-off-by: Anthony Liguori --- vnc.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/vnc.c b/vnc.c index 9dbe82ac06..5eaef6a3e2 100644 --- a/vnc.c +++ b/vnc.c @@ -2274,6 +2274,11 @@ int vnc_display_password(DisplayState *ds, const char *password) if (password && password[0]) { if (!(vs->password = qemu_strdup(password))) return -1; + if (vs->auth == VNC_AUTH_NONE) { + vs->auth = VNC_AUTH_VNC; + } + } else { + vs->auth = VNC_AUTH_NONE; } return 0;