From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50644) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vu2In-0005Ix-FK for qemu-devel@nongnu.org; Fri, 20 Dec 2013 10:47:55 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vu2Ih-0000zL-Fi for qemu-devel@nongnu.org; Fri, 20 Dec 2013 10:47:49 -0500 Received: from mx1.redhat.com ([209.132.183.28]:56104) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vu2Ih-0000zA-7e for qemu-devel@nongnu.org; Fri, 20 Dec 2013 10:47:43 -0500 From: Stefan Hajnoczi Date: Fri, 20 Dec 2013 16:46:56 +0100 Message-Id: <1387554416-5837-19-git-send-email-stefanha@redhat.com> In-Reply-To: <1387554416-5837-1-git-send-email-stefanha@redhat.com> References: <1387554416-5837-1-git-send-email-stefanha@redhat.com> Subject: [Qemu-devel] [PULL 18/18] commit: Remove unused check List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Anthony Liguori From: Fam Zheng We support top == active for commit now, remove the check and add an assertion here. Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf Signed-off-by: Stefan Hajnoczi --- block/commit.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/block/commit.c b/block/commit.c index d4090cb..acec4ac 100644 --- a/block/commit.c +++ b/block/commit.c @@ -198,13 +198,7 @@ void commit_start(BlockDriverState *bs, BlockDriverState *base, return; } - /* Once we support top == active layer, remove this check */ - if (top == bs) { - error_setg(errp, - "Top image as the active layer is currently unsupported"); - return; - } - + assert(top != bs); if (top == base) { error_setg(errp, "Invalid files for merge: top and base are the same"); return; -- 1.8.4.2