]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemu: hotplug: Use checker function to check if disk is empty
authorPeter Krempa <pkrempa@redhat.com>
Thu, 12 Mar 2015 15:57:56 +0000 (16:57 +0100)
committerCole Robinson <crobinso@redhat.com>
Tue, 28 Apr 2015 15:06:41 +0000 (11:06 -0400)
(cherry picked from commit e7974b4f80f320c9232ff31762fd1aa82a590f2e)

src/qemu/qemu_hotplug.c

index 08047ce1f4ee43fdbc67cdf62645a58efa06a8c3..ca0ec47fa6e4f51d04b2f7873dcdfe321867c709 100644 (file)
@@ -222,7 +222,7 @@ qemuDomainChangeEjectableMedia(virQEMUDriverPtr driver,
         goto error;
     }
 
-    if (!virStorageSourceIsLocalStorage(newsrc) || newsrc->path) {
+    if (!virStorageSourceIsEmpty(newsrc)) {
         if (qemuGetDriveSourceString(newsrc, conn, &sourcestr) < 0)
             goto error;