thebeanogamer / rpms / qemu-kvm

Forked from rpms/qemu-kvm 5 months ago
Clone
0a122b
From 1d78e14b1774a799db6336a4381f91a7af295f38 Mon Sep 17 00:00:00 2001
0a122b
From: Fam Zheng <famz@redhat.com>
0a122b
Date: Fri, 17 Jan 2014 03:08:03 +0100
0a122b
Subject: [PATCH 20/34] commit: Remove unused check
0a122b
0a122b
RH-Author: Fam Zheng <famz@redhat.com>
0a122b
Message-id: <1389928083-8921-19-git-send-email-famz@redhat.com>
0a122b
Patchwork-id: 56780
0a122b
O-Subject: [RHEL-7 qemu-kvm PATCH 18/18] commit: Remove unused check
0a122b
Bugzilla: 1041301
0a122b
RH-Acked-by: Jeffrey Cody <jcody@redhat.com>
0a122b
RH-Acked-by: Kevin Wolf <kwolf@redhat.com>
0a122b
RH-Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
0a122b
0a122b
We support top == active for commit now, remove the check and add an
0a122b
assertion here.
0a122b
0a122b
Signed-off-by: Fam Zheng <famz@redhat.com>
0a122b
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
0a122b
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
0a122b
(cherry picked from commit 18da7f94cdce130f2a71387de4980ffa817181a1)
0a122b
Signed-off-by: Fam Zheng <famz@redhat.com>
0a122b
---
0a122b
 block/commit.c | 8 +-------
0a122b
 1 file changed, 1 insertion(+), 7 deletions(-)
0a122b
0a122b
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
0a122b
---
0a122b
 block/commit.c |    8 +-------
0a122b
 1 files changed, 1 insertions(+), 7 deletions(-)
0a122b
0a122b
diff --git a/block/commit.c b/block/commit.c
0a122b
index d237729..e3e395d 100644
0a122b
--- a/block/commit.c
0a122b
+++ b/block/commit.c
0a122b
@@ -198,13 +198,7 @@ void commit_start(BlockDriverState *bs, BlockDriverState *base,
0a122b
         return;
0a122b
     }
0a122b
 
0a122b
-    /* Once we support top == active layer, remove this check */
0a122b
-    if (top == bs) {
0a122b
-        error_setg(errp,
0a122b
-                   "Top image as the active layer is currently unsupported");
0a122b
-        return;
0a122b
-    }
0a122b
-
0a122b
+    assert(top != bs);
0a122b
     if (top == base) {
0a122b
         error_setg(errp, "Invalid files for merge: top and base are the same");
0a122b
         return;
0a122b
-- 
0a122b
1.7.1
0a122b