spice: call qemu_spice_set_passwd() during init
authorMarc-André Lureau <marcandre.lureau@gmail.com>
Fri, 5 Sep 2014 12:08:48 +0000 (14:08 +0200)
committerGerd Hoffmann <kraxel@redhat.com>
Tue, 16 Sep 2014 06:09:03 +0000 (08:09 +0200)
Don't call SPICE API directly to set password given in command line, but
use the internal API, saving password for later calls.

This solves losing password when changing expiration in qemu monitor.

https://bugzilla.redhat.com/show_bug.cgi?id=1138639

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
ui/spice-core.c

index 17a2ed3..6467fa4 100644 (file)
@@ -733,7 +733,7 @@ void qemu_spice_init(void)
                              tls_ciphers);
     }
     if (password) {
-        spice_server_set_ticket(spice_server, password, 0, 0, 0);
+        qemu_spice_set_passwd(password, false, false);
     }
     if (qemu_opt_get_bool(opts, "sasl", 0)) {
         if (spice_server_set_sasl_appname(spice_server, "qemu") == -1 ||