Blame SOURCES/libvirt-qemuCheckpointDiscardBitmaps-Use-correct-field-for-checkpoint-bitmap-name.patch

d76c62
From ec3392c1d5a9886279ee086ee3d421106b9b1e32 Mon Sep 17 00:00:00 2001
d76c62
Message-Id: <ec3392c1d5a9886279ee086ee3d421106b9b1e32@dist-git>
d76c62
From: Peter Krempa <pkrempa@redhat.com>
d76c62
Date: Mon, 16 Mar 2020 22:12:18 +0100
d76c62
Subject: [PATCH] qemuCheckpointDiscardBitmaps: Use correct field for
d76c62
 checkpoint bitmap name
d76c62
MIME-Version: 1.0
d76c62
Content-Type: text/plain; charset=UTF-8
d76c62
Content-Transfer-Encoding: 8bit
d76c62
d76c62
The code deleting checkpoints needs the name of the parent checkpoint's
d76c62
disk's bitmap but was using the disk alias instead. This would create
d76c62
wrong bitmaps after deleting some checkpoints.
d76c62
d76c62
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
d76c62
Reviewed-by: Eric Blake <eblake@redhat.com>
d76c62
(cherry picked from commit 0ce8b0fbe2d0cbaf26da0402270720b776ebfb0f)
d76c62
https://bugzilla.redhat.com/show_bug.cgi?id=1799013
d76c62
Message-Id: <c32db1af44e71870d172233acdfddf050ed73441.1584391727.git.pkrempa@redhat.com>
d76c62
Reviewed-by: Ján Tomko <jtomko@redhat.com>
d76c62
---
d76c62
 src/qemu/qemu_checkpoint.c | 2 +-
d76c62
 1 file changed, 1 insertion(+), 1 deletion(-)
d76c62
d76c62
diff --git a/src/qemu/qemu_checkpoint.c b/src/qemu/qemu_checkpoint.c
d76c62
index 6e3a432022..19822bd74d 100644
d76c62
--- a/src/qemu/qemu_checkpoint.c
d76c62
+++ b/src/qemu/qemu_checkpoint.c
d76c62
@@ -285,7 +285,7 @@ qemuCheckpointDiscardBitmaps(virDomainObjPtr vm,
d76c62
          * ancestor. */
d76c62
         if ((parentchkdisk = qemuCheckpointFindActiveDiskInParent(vm, parent,
d76c62
                                                                   chkdisk->name)))
d76c62
-            parentbitmap = parentchkdisk->name;
d76c62
+            parentbitmap = parentchkdisk->bitmap;
d76c62
 
d76c62
         if (qemuCheckpointDiscardDiskBitmaps(domdisk->src, blockNamedNodeData,
d76c62
                                              chkdisk->bitmap, parentbitmap,
d76c62
-- 
d76c62
2.25.1
d76c62