qemu: hotplug: Use checker function to check if disk is empty

(cherry picked from commit e7974b4f80)
This commit is contained in:
Peter Krempa 2015-03-12 16:57:56 +01:00 committed by Cole Robinson
parent 7d11e8de0b
commit 2c3aba719a

View 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;