mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 03:12:22 +00:00
qemu: Fix logic bug in inactive snapshot deletion
Commit 926563dc3a6 which refactored the function call deleting the snapshot's on disk state introduced a logic bug, which skips over the deletion of libvirt metadata after the disk state deletion is done. To fix it we must not return early. Resolves: https://gitlab.com/libvirt/libvirt/-/issues/109 Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Erik Skultety <eskultet@redhat.com>
This commit is contained in:
parent
2319253bcd
commit
0ddebdb42e
@ -6666,7 +6666,8 @@ qemuDomainSnapshotDiscard(virQEMUDriverPtr driver,
|
||||
if (!def)
|
||||
def = vm->def;
|
||||
|
||||
return qemuDomainSnapshotForEachQcow2(driver, def, snap, "-d", true);
|
||||
if (qemuDomainSnapshotForEachQcow2(driver, def, snap, "-d", true) < 0)
|
||||
return -1;
|
||||
} else {
|
||||
priv = vm->privateData;
|
||||
qemuDomainObjEnterMonitor(driver, vm);
|
||||
|
Loading…
x
Reference in New Issue
Block a user