aboutsummaryrefslogtreecommitdiffstats
path: root/fs/proc
diff options
context:
space:
mode:
authorJames Morris <jmorris@namei.org>2009-06-10 21:03:14 -0400
committerJames Morris <jmorris@namei.org>2009-06-10 21:03:14 -0400
commit73fbad283cfbbcf02939bdbda31fc4a30e729cca (patch)
tree7c89fe13e1b4a2c7f2d60f4ea6eaf69c14bccab7 /fs/proc
parent769f3e8c384795cc350e2aae27de2a12374d19d4 (diff)
parent35f2c2f6f6ae13ef23c4f68e6d3073753077ca43 (diff)
Merge branch 'next' into for-linus
Diffstat (limited to 'fs/proc')
-rw-r--r--fs/proc/base.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c
index 3326bbf9ab95..1539e630c47d 100644
--- a/fs/proc/base.c
+++ b/fs/proc/base.c
@@ -2128,9 +2128,15 @@ static ssize_t proc_pid_attr_write(struct file * file, const char __user * buf,
2128 if (copy_from_user(page, buf, count)) 2128 if (copy_from_user(page, buf, count))
2129 goto out_free; 2129 goto out_free;
2130 2130
2131 /* Guard against adverse ptrace interaction */
2132 length = mutex_lock_interruptible(&task->cred_guard_mutex);
2133 if (length < 0)
2134 goto out_free;
2135
2131 length = security_setprocattr(task, 2136 length = security_setprocattr(task,
2132 (char*)file->f_path.dentry->d_name.name, 2137 (char*)file->f_path.dentry->d_name.name,
2133 (void*)page, count); 2138 (void*)page, count);
2139 mutex_unlock(&task->cred_guard_mutex);
2134out_free: 2140out_free:
2135 free_page((unsigned long) page); 2141 free_page((unsigned long) page);
2136out: 2142out: