It does not make a difference. qemuDomainSaveMemory ret code is either 0 or -1. If it is -1 then ret is already set to -1. If it is 0 then it is overwritten by qemuSnapshotCreateActiveExternalDisks anyway. Signed-off-by: Nikolay Shirokovskiy <nshirokovskiy@xxxxxxxxxxxxx> --- src/qemu/qemu_snapshot.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index aa9b2ebbd9..8656affa25 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -1451,9 +1451,9 @@ qemuSnapshotCreateActiveExternal(virQEMUDriver *driver, memory_existing = virFileExists(snapdef->memorysnapshotfile); - if ((ret = qemuSaveImageCreate(driver, vm, snapdef->memorysnapshotfile, - data, compressor, 0, - QEMU_ASYNC_JOB_SNAPSHOT)) < 0) + if (qemuSaveImageCreate(driver, vm, snapdef->memorysnapshotfile, + data, compressor, 0, + QEMU_ASYNC_JOB_SNAPSHOT) < 0) goto cleanup; /* the memory image was created, remove it on errors */ -- 2.27.0