qemu: Properly release job in qemuDomainSaveInternal

The function would fail to release the job in case
qemuMigrationSrcIsAllowed failed.

Fixes v8.5.0-157-g69e0e33873

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
Jiri Denemark 2022-07-27 15:40:12 +02:00
parent ef53798ab6
commit 9c3d398df1

View File

@ -2656,7 +2656,7 @@ qemuDomainSaveInternal(virQEMUDriver *driver,
goto cleanup;
if (!qemuMigrationSrcIsAllowed(driver, vm, false, VIR_ASYNC_JOB_SAVE, 0))
goto cleanup;
goto endjob;
if (!virDomainObjIsActive(vm)) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",