From: Peter Krempa Date: Tue, 29 May 2018 16:30:10 +0000 (+0200) Subject: qemu: hotplug: Allow passing in NULL 'tlsAlias' to qemuDomainGetTLSObjects X-Git-Tag: v4.5.0-rc1~323 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=da49ff2c0192cca44c6fa9dce65a43af220a12aa;p=thirdparty%2Flibvirt.git qemu: hotplug: Allow passing in NULL 'tlsAlias' to qemuDomainGetTLSObjects Some callers will not need to generate the alias again. Signed-off-by: Peter Krempa Reviewed-by: Ján Tomko --- diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index 713f88fcf5..1d9381ea5c 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -1523,7 +1523,8 @@ qemuDomainGetTLSObjects(virQEMUCapsPtr qemuCaps, tlsProps) < 0) return -1; - if (!(*tlsAlias = qemuAliasTLSObjFromSrcAlias(srcAlias))) + if (tlsAlias && + !(*tlsAlias = qemuAliasTLSObjFromSrcAlias(srcAlias))) return -1; return 0;