projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0c55cfc
)
userns: fix return value on mntns_install() failure
author
Zhao Hongjiang
<zhaohongjiang@huawei.com>
Thu, 13 Sep 2012 08:38:03 +0000
(16:38 +0800)
committer
Eric W. Biederman
<ebiederm@xmission.com>
Mon, 19 Nov 2012 13:59:22 +0000
(
05:59
-0800)
Change return value from -EINVAL to -EPERM when the permission check fails.
Signed-off-by: Zhao Hongjiang <zhaohongjiang@huawei.com>
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
fs/namespace.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/namespace.c
b/fs/namespace.c
index 9ddc86f93221ff528093b65e3f9e6626ba81c283..cab78a74aca3534f5bac93d7a41c5a7972389df0 100644
(file)
--- a/
fs/namespace.c
+++ b/
fs/namespace.c
@@
-2775,7
+2775,7
@@
static int mntns_install(struct nsproxy *nsproxy, void *ns)
if (!ns_capable(mnt_ns->user_ns, CAP_SYS_ADMIN) ||
!nsown_capable(CAP_SYS_CHROOT))
- return -E
INVAL
;
+ return -E
PERM
;
if (fs->users != 1)
return -EINVAL;