]> git.proxmox.com Git - pve-qemu.git/blame - debian/patches/bitmap-mirror/0003-mirror-add-check-for-bitmap-mode-without-bitmap.patch
update submodule and patches to 7.1.0
[pve-qemu.git] / debian / patches / bitmap-mirror / 0003-mirror-add-check-for-bitmap-mode-without-bitmap.patch
CommitLineData
83faa3fe 1From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
059a9447 2From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler@proxmox.com>
83faa3fe
TL
3Date: Mon, 6 Apr 2020 12:17:05 +0200
4Subject: [PATCH] mirror: add check for bitmap-mode without bitmap
059a9447
FG
5MIME-Version: 1.0
6Content-Type: text/plain; charset=UTF-8
7Content-Transfer-Encoding: 8bit
8
9as one without the other does not make much sense with the current set
10of modes.
11
12Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
ddbf7a87 13Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
059a9447
FG
14---
15 blockdev.c | 3 +++
16 1 file changed, 3 insertions(+)
17
18diff --git a/blockdev.c b/blockdev.c
5b15e2ec 19index 9a1a3118ed..a57b0af2e7 100644
059a9447
FG
20--- a/blockdev.c
21+++ b/blockdev.c
dc9827a6 22@@ -3050,6 +3050,9 @@ static void blockdev_mirror_common(const char *job_id, BlockDriverState *bs,
059a9447
FG
23 if (bdrv_dirty_bitmap_check(bitmap, BDRV_BITMAP_ALLOW_RO, errp)) {
24 return;
25 }
26+ } else if (has_bitmap_mode) {
27+ error_setg(errp, "Cannot specify bitmap sync mode without a bitmap");
28+ return;
29 }
30
817b7667 31 if (!has_replaces) {