]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemu: On attach to live XML check for user alias collision only live XML
authorMichal Privoznik <mprivozn@redhat.com>
Fri, 26 Apr 2019 13:30:40 +0000 (15:30 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Fri, 26 Apr 2019 13:47:36 +0000 (15:47 +0200)
When attaching a device to live XML we don't care (well,
shouldn't care) that there's already a device in inactive XML
that has the same user alias.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
src/qemu/qemu_driver.c

index 2b2d53144109902c656e5c0c4b3d64c9df9d1328..40fd8b9d2dfe294f00b9cbabd6c2a0f90a153a1b 100644 (file)
@@ -8663,7 +8663,8 @@ qemuDomainAttachDeviceLiveAndConfig(virDomainObjPtr vm,
                                                 driver->xmlopt, parse_flags)))
             goto cleanup;
 
-        if (virDomainDeviceValidateAliasForHotplug(vm, devLive, flags) < 0)
+        if (virDomainDeviceValidateAliasForHotplug(vm, devLive,
+                                                   VIR_DOMAIN_AFFECT_LIVE) < 0)
             goto cleanup;
 
         if (virDomainDefCompatibleDevice(vm->def, devLive, NULL,