]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: fix domxml-to-native failing when spice_tls is not enabled
authorJincheng Miao <jmiao@redhat.com>
Fri, 27 Jun 2014 14:37:02 +0000 (22:37 +0800)
committerJán Tomko <jtomko@redhat.com>
Wed, 9 Jul 2014 10:29:55 +0000 (12:29 +0200)
commite871ab8862e48485c46177dcfd95da8f945908ae
treecb3abed6e4e015f7a8b2783f059173481cd3fb66
parent52c21204aa7f822c7335d7a75e7177232d6a8741
qemu: fix domxml-to-native failing when spice_tls is not enabled

The default graphics channel mode is 'any', so as to defaultMode attribute.
If defaultMode and channel mode are all the default value 'any',
qemuConnectDomainXMLToNative will set TLSPort.
But in qemuBuildGraphicsSPICECommandLine, if spice_tls is not enabled, libvirtd
will report an error to tell the user that spice TLS is disabled in qemu.conf.

So qemuConnectDomainXMLToNative should check spice_tls is enabled,
then decide to allocate an tlsPort number to this graphics.

If user specified defaultMode is 'secure', qemuConnectDomainXMLToNative
could allocate tlsPort, and then let qemuBuildGraphicsSPICECommandLine reports
the spice_tls disabled error.

The related bug is:
https://bugzilla.redhat.com/show_bug.cgi?id=1113868

Signed-off-by: Jincheng Miao <jmiao@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
src/qemu/qemu_driver.c