mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-10-23 14:33:10 +00:00
qemu_command: move websocket code into else part for address listen
There is no need to check again for vnc socket. Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
parent
326e5941cd
commit
fdff47c587
@ -7257,17 +7257,16 @@ qemuBuildGraphicsVNCCommandLine(virQEMUDriverConfigPtr cfg,
|
||||
}
|
||||
virBufferAsprintf(&opt, ":%d",
|
||||
graphics->data.vnc.port - 5900);
|
||||
}
|
||||
|
||||
if (!graphics->data.vnc.socket &&
|
||||
graphics->data.vnc.websocket) {
|
||||
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_VNC_WEBSOCKET)) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
|
||||
_("VNC WebSockets are not supported "
|
||||
"with this QEMU binary"));
|
||||
goto error;
|
||||
if (graphics->data.vnc.websocket) {
|
||||
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_VNC_WEBSOCKET)) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
|
||||
_("VNC WebSockets are not supported "
|
||||
"with this QEMU binary"));
|
||||
goto error;
|
||||
}
|
||||
virBufferAsprintf(&opt, ",websocket=%d", graphics->data.vnc.websocket);
|
||||
}
|
||||
virBufferAsprintf(&opt, ",websocket=%d", graphics->data.vnc.websocket);
|
||||
}
|
||||
|
||||
if (graphics->data.vnc.sharePolicy) {
|
||||
|
Loading…
Reference in New Issue
Block a user