summaryrefslogtreecommitdiff
path: root/fs/f2fs/acl.c
diff options
context:
space:
mode:
authorKinglong Mee <kinglongmee@gmail.com>2015-01-24 17:06:25 +0800
committerJaegeuk Kim <jaegeuk@kernel.org>2015-02-11 17:04:36 -0800
commit3b6709b771b3335856643df8f6e0158db150a438 (patch)
tree9a948b01565b5d16bab57326764196da0db9c399 /fs/f2fs/acl.c
parentf28e503429644a794d9bf2793189ff0b0887eb21 (diff)
downloadlinux-rpi-3b6709b771b3335856643df8f6e0158db150a438.tar.gz
linux-rpi-3b6709b771b3335856643df8f6e0158db150a438.tar.bz2
linux-rpi-3b6709b771b3335856643df8f6e0158db150a438.zip
f2fs: fix a bug of inheriting default ACL from parent
Introduced by a6dda0e63e97122ce9e0ba04367e37cca28315fa "f2fs: use generic posix ACL infrastructure". When testing default acl, gets in recent kernel (3.19.0-rc5), user::rwx group::r-x other::r-x default:user::rwx default:group::r-x default:group:root:rwx default:mask::rwx default:other::r-x ]# getfacl testdir/ user::rwx group::rwx // missing an acl "group:root:rwx" inherited from parent other::r-x default:user::rwx default:group::r-x default:group:root:rwx default:mask::rwx default:other::r-x Signed-off-by: Kinglong Mee <kinglongmee@gmail.com> Reviewed-by: Chao Yu <chao2.yu@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/acl.c')
-rw-r--r--fs/f2fs/acl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/acl.c b/fs/f2fs/acl.c
index 7f12d28ad94c..742202779bd5 100644
--- a/fs/f2fs/acl.c
+++ b/fs/f2fs/acl.c
@@ -396,7 +396,7 @@ int f2fs_init_acl(struct inode *inode, struct inode *dir, struct page *ipage,
posix_acl_release(default_acl);
}
if (acl) {
- if (error)
+ if (!error)
error = __f2fs_set_acl(inode, ACL_TYPE_ACCESS, acl,
ipage);
posix_acl_release(acl);