Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 312952
b: refs/heads/master
c: d35abdb
h: refs/heads/master
v: v3
  • Loading branch information
Al Viro committed Jul 22, 2012
1 parent 606da78 commit 15c8f9f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6120d3dbb1220792ebea88cd475e1ec8f8620a93
refs/heads/master: d35abdb28824cf74f0a106a0f9c6f3ff700a35bf
2 changes: 2 additions & 0 deletions trunk/security/keys/keyctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1486,6 +1486,7 @@ long keyctl_session_to_parent(void)
oldwork = NULL;
parent = me->real_parent;

task_lock(parent);
/* the parent mustn't be init and mustn't be a kernel thread */
if (parent->pid <= 1 || !parent->mm)
goto unlock;
Expand Down Expand Up @@ -1529,6 +1530,7 @@ long keyctl_session_to_parent(void)
if (!ret)
newwork = NULL;
unlock:
task_unlock(parent);
write_unlock_irq(&tasklist_lock);
rcu_read_unlock();
if (oldwork)
Expand Down

0 comments on commit 15c8f9f

Please sign in to comment.