summaryrefslogtreecommitdiff
path: root/fs/posix_acl.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2016-10-08 11:00:01 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2016-10-08 11:00:01 -0400
commitf334bcd94b7d3c0fbc34d518a86548f451ab5faf (patch)
tree357b0cbd488db581bc9bf710c3696579d21fac03 /fs/posix_acl.c
parent73e8fb2d596d5903cde6dcced39c0b88b5770a56 (diff)
parent814184fd402557f3e5960db469157ccdf1fb69da (diff)
Merge remote-tracking branch 'ovl/misc' into work.misc
Diffstat (limited to 'fs/posix_acl.c')
-rw-r--r--fs/posix_acl.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/fs/posix_acl.c b/fs/posix_acl.c
index 8cdcbb1dd092..87193924eb91 100644
--- a/fs/posix_acl.c
+++ b/fs/posix_acl.c
@@ -598,13 +598,14 @@ posix_acl_create(struct inode *dir, umode_t *mode,
if (IS_ERR(p))
return PTR_ERR(p);
+ ret = -ENOMEM;
clone = posix_acl_clone(p, GFP_NOFS);
if (!clone)
- goto no_mem;
+ goto err_release;
ret = posix_acl_create_masq(clone, mode);
if (ret < 0)
- goto no_mem_clone;
+ goto err_release_clone;
if (ret == 0)
posix_acl_release(clone);
@@ -618,11 +619,11 @@ posix_acl_create(struct inode *dir, umode_t *mode,
return 0;
-no_mem_clone:
+err_release_clone:
posix_acl_release(clone);
-no_mem:
+err_release:
posix_acl_release(p);
- return -ENOMEM;
+ return ret;
}
EXPORT_SYMBOL_GPL(posix_acl_create);