From: Pavel Hrdina Date: Thu, 25 Nov 2021 16:08:35 +0000 (+0100) Subject: qemu_snapshot: revert: remove cleanup label X-Git-Tag: v8.0.0-rc1~388 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2bbbb201eeaf2295e22b2e14351e10a7d744b40b;p=thirdparty%2Flibvirt.git qemu_snapshot: revert: remove cleanup label Now the cleanup label is not necessary so we can drop it. Signed-off-by: Pavel Hrdina Reviewed-by: Ján Tomko --- diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 8191733a6d..beeb012431 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -1967,13 +1967,13 @@ qemuSnapshotRevert(virDomainObj *vm, if (qemuDomainHasBlockjob(vm, false)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", _("domain has active block job")); - goto cleanup; + return -1; } if (qemuProcessBeginJob(driver, vm, VIR_DOMAIN_JOB_OPERATION_SNAPSHOT_REVERT, flags) < 0) - goto cleanup; + return -1; if (!(snap = qemuSnapObjFromSnapshot(vm, snapshot))) goto endjob; @@ -2210,7 +2210,6 @@ qemuSnapshotRevert(virDomainObj *vm, endjob: qemuProcessEndJob(driver, vm); - cleanup: if (ret == 0) { qemuSnapshotSetCurrent(vm, snap); if (qemuDomainSnapshotWriteMetadata(vm, snap,