From: Michal Nazarewicz Date: Fri, 29 Nov 2013 17:01:15 +0000 (+0100) Subject: btrfs: remove dead code X-Git-Tag: v3.14-rc2~3^2~109 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=11850392ee1c600c7d40d93119daa72715bc959c;p=profile%2Fcommon%2Fkernel-common.git btrfs: remove dead code [commit 8185554d: fix incorrect inode acl reset] introduced a dead code by adding a condition which can never be true to an else branch. The condition can never be true because it is already checked by a previous if statement which causes function to return. Signed-off-by: Michal Nazarewicz Reviewed-By: Filipe David Borba Manana Signed-off-by: Josef Bacik Signed-off-by: Chris Mason --- diff --git a/fs/btrfs/acl.c b/fs/btrfs/acl.c index 0890c83..460f36b 100644 --- a/fs/btrfs/acl.c +++ b/fs/btrfs/acl.c @@ -225,13 +225,8 @@ int btrfs_init_acl(struct btrfs_trans_handle *trans, ret = posix_acl_create(&acl, GFP_NOFS, &inode->i_mode); if (ret < 0) return ret; - - if (ret > 0) { - /* we need an acl */ + if (ret > 0) /* we need an acl */ ret = btrfs_set_acl(trans, inode, acl, ACL_TYPE_ACCESS); - } else if (ret < 0) { - cache_no_acl(inode); - } } else { cache_no_acl(inode); }