render / rpms / libvirt

Forked from rpms/libvirt 9 months ago
Clone
a41c76
From 9bec4051732e43d24808893643826268ab88b8cc Mon Sep 17 00:00:00 2001
a41c76
Message-Id: <9bec4051732e43d24808893643826268ab88b8cc@dist-git>
a41c76
From: Peter Krempa <pkrempa@redhat.com>
a41c76
Date: Tue, 23 Jun 2020 12:24:09 +0200
a41c76
Subject: [PATCH] qemuBackupDiskStarted: Fix improper dereference of array
a41c76
MIME-Version: 1.0
a41c76
Content-Type: text/plain; charset=UTF-8
a41c76
Content-Transfer-Encoding: 8bit
a41c76
a41c76
The code would repeatedly mark the first disk's blockjob as started
a41c76
rather than accessing all the blockjobs. Fix the dereferencing operator.
a41c76
a41c76
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
a41c76
Reviewed-by: Ján Tomko <jtomko@redhat.com>
a41c76
(cherry picked from commit 214faa0b04ace42aebfa40e1d19aabbf3003f0fe)
a41c76
https://bugzilla.redhat.com/show_bug.cgi?id=1804593
a41c76
Message-Id: <1d33c3080e24baf96a0d9435d1588b4a48a98425.1592906423.git.pkrempa@redhat.com>
a41c76
Reviewed-by: Ján Tomko <jtomko@redhat.com>
a41c76
---
a41c76
 src/qemu/qemu_backup.c | 2 +-
a41c76
 1 file changed, 1 insertion(+), 1 deletion(-)
a41c76
a41c76
diff --git a/src/qemu/qemu_backup.c b/src/qemu/qemu_backup.c
a41c76
index 013a82e06d..fdc75d3160 100644
a41c76
--- a/src/qemu/qemu_backup.c
a41c76
+++ b/src/qemu/qemu_backup.c
a41c76
@@ -479,7 +479,7 @@ qemuBackupDiskStarted(virDomainObjPtr vm,
a41c76
     for (i = 0; i < ndd; i++) {
a41c76
         dd[i].started = true;
a41c76
         dd[i].backupdisk->state = VIR_DOMAIN_BACKUP_DISK_STATE_RUNNING;
a41c76
-        qemuBlockJobStarted(dd->blockjob, vm);
a41c76
+        qemuBlockJobStarted(dd[i].blockjob, vm);
a41c76
     }
a41c76
 }
a41c76
 
a41c76
-- 
a41c76
2.27.0
a41c76