diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-07-14 21:48:03 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-07-14 21:48:03 -0700 |
commit | 9ee8ab9fbf21e6b87ad227cd46c0a4be41ab749b (patch) | |
tree | 148cf933d20fdf79096b71d03552c1c511c2db13 /fs/proc | |
parent | 18b0bbd8ca6d3cb90425aa0d77b99a762c6d6de3 (diff) | |
download | kernel_samsung_crespo-9ee8ab9fbf21e6b87ad227cd46c0a4be41ab749b.zip kernel_samsung_crespo-9ee8ab9fbf21e6b87ad227cd46c0a4be41ab749b.tar.gz kernel_samsung_crespo-9ee8ab9fbf21e6b87ad227cd46c0a4be41ab749b.tar.bz2 |
Relax /proc fix a bit
Clearign all of i_mode was a bit draconian. We only really care about
S_ISUID/ISGID, after all.
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/proc')
-rw-r--r-- | fs/proc/base.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c index 0cb8f20..474eae3 100644 --- a/fs/proc/base.c +++ b/fs/proc/base.c @@ -1338,8 +1338,8 @@ static int pid_revalidate(struct dentry *dentry, struct nameidata *nd) } else { inode->i_uid = 0; inode->i_gid = 0; - inode->i_mode = 0; } + inode->i_mode &= ~(S_ISUID | S_ISGID); security_task_to_inode(task, inode); put_task_struct(task); return 1; @@ -1390,6 +1390,7 @@ static int tid_fd_revalidate(struct dentry *dentry, struct nameidata *nd) inode->i_uid = 0; inode->i_gid = 0; } + inode->i_mode &= ~(S_ISUID | S_ISGID); security_task_to_inode(task, inode); put_task_struct(task); return 1; |