From 5ca6c34bdeb02ea355a0e5ef9ff51581b58c1ee7 Mon Sep 17 00:00:00 2001 From: Dwight Engen Date: Tue, 7 May 2013 10:57:16 -0400 Subject: [PATCH] coverity: condition already checked for Signed-off-by: Dwight Engen Acked-by: Serge E. Hallyn --- src/lxc/bdev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/lxc/bdev.c b/src/lxc/bdev.c index 181e98ea1..fcde16b51 100644 --- a/src/lxc/bdev.c +++ b/src/lxc/bdev.c @@ -1151,8 +1151,7 @@ static int overlayfs_clonepaths(struct bdev *orig, struct bdev *new, const char if (strcmp(orig->type, "dir") == 0) { char *delta; int ret, len; - if (!snap) - return -1; + // if we have /var/lib/lxc/c2/rootfs, then delta will be // /var/lib/lxc/c2/delta0 delta = strdup(new->dest);