mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 06:05:27 +00:00
qemu: command: escape commas in VNC socket path
This path can be dependent on the VM libdir, which contains its name
This commit is contained in:
parent
3153ac08c9
commit
077ba95677
@ -7425,7 +7425,8 @@ qemuBuildGraphicsVNCCommandLine(virQEMUDriverConfigPtr cfg,
|
||||
graphics->data.vnc.socketAutogenerated = true;
|
||||
}
|
||||
|
||||
virBufferAsprintf(&opt, "unix:%s", graphics->data.vnc.socket);
|
||||
virBufferAddLit(&opt, "unix:");
|
||||
qemuBufferEscapeComma(&opt, graphics->data.vnc.socket);
|
||||
|
||||
} else {
|
||||
if (!graphics->data.vnc.autoport &&
|
||||
|
@ -13,7 +13,6 @@ bar/master-key.aes \
|
||||
-m 214 \
|
||||
-smp 1 \
|
||||
-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \
|
||||
-nographic \
|
||||
-nodefaults \
|
||||
-chardev socket,id=charmonitor,path=/tmp/lib/domain--1-foo,bar/monitor.sock,\
|
||||
server,nowait \
|
||||
@ -21,4 +20,6 @@ server,nowait \
|
||||
-no-acpi \
|
||||
-boot c \
|
||||
-usb \
|
||||
-vnc unix:/tmp/bar,,foo.sock \
|
||||
-vga cirrus \
|
||||
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3
|
||||
|
@ -14,5 +14,6 @@
|
||||
<on_crash>destroy</on_crash>
|
||||
<devices>
|
||||
<emulator>/usr/bin/qemu</emulator>
|
||||
<graphics type='vnc' socket='/tmp/bar,foo.sock'/>
|
||||
</devices>
|
||||
</domain>
|
||||
|
@ -1903,7 +1903,7 @@ mymain(void)
|
||||
NONE);
|
||||
|
||||
DO_TEST("name-escape", QEMU_CAPS_NAME_DEBUG_THREADS,
|
||||
QEMU_CAPS_OBJECT_SECRET, QEMU_CAPS_CHARDEV);
|
||||
QEMU_CAPS_OBJECT_SECRET, QEMU_CAPS_CHARDEV, QEMU_CAPS_VNC);
|
||||
DO_TEST("debug-threads", QEMU_CAPS_NAME_DEBUG_THREADS);
|
||||
|
||||
DO_TEST("master-key", QEMU_CAPS_OBJECT_SECRET);
|
||||
|
Loading…
Reference in New Issue
Block a user