qemu: hotplug: Don't generate alias when detaching disk

It should be impossible to lack an alias in the domain definition. Other
disk types don't generate it so remove it here as well.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
Peter Krempa 2018-07-24 14:39:46 +02:00
parent c3543a3217
commit 2bd9db9659

View File

@ -4915,11 +4915,6 @@ qemuDomainDetachVirtioDiskDevice(virQEMUDriverPtr driver,
goto cleanup;
}
if (!detach->info.alias) {
if (qemuAssignDeviceDiskAlias(vm->def, detach) < 0)
goto cleanup;
}
if (!async)
qemuDomainMarkDeviceForRemoval(vm, &detach->info);