[PATCH v4 05/14] qemu_command: move sasl parameter after port and addr definition

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is required for following patches where new listen types will be
introduced.

Signed-off-by: Pavel Hrdina <phrdina@xxxxxxxxxx>
---
 src/qemu/qemu_command.c                              | 20 ++++++++++----------
 .../qemuxml2argv-graphics-spice-sasl.args            |  2 +-
 2 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 61ab30e..e5847f7 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -7566,16 +7566,6 @@ qemuBuildGraphicsSPICECommandLine(virQEMUDriverConfigPtr cfg,
         virBufferAsprintf(&opt, "tls-port=%u,", tlsPort);
     }
 
-    if (cfg->spiceSASL) {
-        virBufferAddLit(&opt, "sasl,");
-
-        if (cfg->spiceSASLdir)
-            virCommandAddEnvPair(cmd, "SASL_CONF_PATH",
-                                 cfg->spiceSASLdir);
-
-        /* TODO: Support ACLs later */
-    }
-
     if (port > 0 || tlsPort > 0) {
         if ((glisten = virDomainGraphicsGetListen(graphics, 0))) {
 
@@ -7619,6 +7609,16 @@ qemuBuildGraphicsSPICECommandLine(virQEMUDriverConfigPtr cfg,
         VIR_FREE(netAddr);
     }
 
+    if (cfg->spiceSASL) {
+        virBufferAddLit(&opt, "sasl,");
+
+        if (cfg->spiceSASLdir)
+            virCommandAddEnvPair(cmd, "SASL_CONF_PATH",
+                                 cfg->spiceSASLdir);
+
+        /* TODO: Support ACLs later */
+    }
+
     if (graphics->data.spice.mousemode) {
         switch (graphics->data.spice.mousemode) {
         case VIR_DOMAIN_GRAPHICS_SPICE_MOUSE_MODE_SERVER:
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-graphics-spice-sasl.args b/tests/qemuxml2argvdata/qemuxml2argv-graphics-spice-sasl.args
index e21d699..bf9045f 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-graphics-spice-sasl.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-graphics-spice-sasl.args
@@ -19,7 +19,7 @@ QEMU_AUDIO_DRV=spice \
 -usb \
 -drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
 -device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
--spice port=5903,tls-port=5904,sasl,addr=127.0.0.1,\
+-spice port=5903,tls-port=5904,addr=127.0.0.1,sasl,\
 x509-dir=/etc/pki/libvirt-spice,tls-channel=default \
 -vga qxl \
 -global qxl-vga.ram_size=67108864 \
-- 
2.8.2

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]