qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 03/10] sheepdog: mark image as snapshot when tag is


From: Kevin Wolf
Subject: [Qemu-devel] [PATCH 03/10] sheepdog: mark image as snapshot when tag is specified
Date: Fri, 25 May 2012 19:38:47 +0200

From: MORITA Kazutaka <address@hidden>

When a snapshot tag is specified in the filename, the opened image is
a snapshot.

Signed-off-by: MORITA Kazutaka <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
---
 block/sheepdog.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/block/sheepdog.c b/block/sheepdog.c
index e01d371..776a1cc 100644
--- a/block/sheepdog.c
+++ b/block/sheepdog.c
@@ -1103,7 +1103,7 @@ static int sd_open(BlockDriverState *bs, const char 
*filename, int flags)
         }
     }
 
-    if (snapid) {
+    if (snapid || tag[0] != '\0') {
         dprintf("%" PRIx32 " snapshot inode was open.\n", vid);
         s->is_snapshot = 1;
     }
-- 
1.7.6.5




reply via email to

[Prev in Thread] Current Thread [Next in Thread]