Skip to contentSkip to conversation

libxl: Fix setting vncpasswd to empty string

PATCH In review Anthony PERARD 3 participants 3 messages Nov 4, 2019 – Nov 8, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 libxl: Fix setting vncpasswd to empty string

Before 93dcc22, error from setting the vnc password to an empty string, when QEMU wasn't expected a password, never prevented the creation of a guest, and only logged an error message.

Fixes 93dcc22fe798c9fa5ce117f1ed6db0d8bd779020
---
 tools/libxl/libxl_dm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tools/libxl/libxl_dm.c +1 -1
index 7e52f0973172..8e0fb78bd2f3 100644
@@ -2936,7 +2936,7 @@ static void device_model_postconfig_vnc(libxl__egc *egc,
         if (rc) goto out;
     }
 
-    if (vnc && vnc->passwd) {
+    if (vnc && vnc->passwd && vnc->passwd[0]) {
         qmp->callback = device_model_postconfig_vnc_passwd;
         libxl__qmp_param_add_string(gc, &args, "password", vnc->passwd);
         rc = libxl__ev_qmp_send(gc, qmp, "change-vnc-password", args);
Signature · 7 lines
Anthony PERARD


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
Acked-by on v1 1/1
#1 lore raw
Quoted 7 lines · Anthony PERARD

Before 93dcc22, error from setting the vnc password to an empty string, when QEMU wasn't expected a password, never prevented the creation of a guest, and only logged an error message.

Fixes 93dcc22fe798c9fa5ce117f1ed6db0d8bd779020

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel

#2 lore raw
In reply to Anthony PERARD
Quoted 7 lines · Anthony PERARD

Before 93dcc22, error from setting the vnc password to an empty string, when QEMU wasn't expected a password, never prevented the creation of a guest, and only logged an error message.

Fixes 93dcc22fe798c9fa5ce117f1ed6db0d8bd779020

Juergen

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel