Replace access via wrapper by direct call to monitor API.
Signed-off-by: Peter Krempa <pkrempa(a)redhat.com>
---
src/qemu/qemu_hotplug.c | 12 ++----------
1 file changed, 2 insertions(+), 10 deletions(-)
diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c
index 6564615597..d8ca894519 100644
--- a/src/qemu/qemu_hotplug.c
+++ b/src/qemu/qemu_hotplug.c
@@ -182,15 +182,6 @@ qemuDomainAddDiskSrcTLSObject(virQEMUDriverPtr driver,
}
-static void
-qemuDomainDelDiskSrcTLSObject(virQEMUDriverPtr driver,
- virDomainObjPtr vm,
- virStorageSourcePtr src)
-{
- qemuDomainDelTLSObjects(driver, vm, QEMU_ASYNC_JOB_NONE, NULL, src->tlsAlias);
-}
-
-
static int
qemuHotplugWaitForTrayEject(virQEMUDriverPtr driver,
virDomainObjPtr vm,
@@ -529,6 +520,8 @@ qemuDomainAttachDiskGeneric(virQEMUDriverPtr driver,
ignore_value(qemuMonitorDelObject(priv->mon, unmanagedPrmgrAlias));
if (managedPrmgrAlias)
ignore_value(qemuMonitorDelObject(priv->mon, managedPrmgrAlias));
+ if (disk->src->tlsAlias)
+ ignore_value(qemuMonitorDelObject(priv->mon, disk->src->tlsAlias));
if (qemuDomainObjExitMonitor(driver, vm) < 0)
ret = -2;
virErrorRestore(&orig_err);
@@ -536,7 +529,6 @@ qemuDomainAttachDiskGeneric(virQEMUDriverPtr driver,
virDomainAuditDisk(vm, NULL, disk->src, "attach", false);
error:
- qemuDomainDelDiskSrcTLSObject(driver, vm, disk->src);
ignore_value(qemuHotplugPrepareDiskAccess(driver, vm, disk, NULL, true));
if (priv->prDaemonRunning &&
!virDomainDefHasManagedPR(vm->def))
--
2.16.2