Skip to content

Commit

Permalink
tomoyo: add missing rcu_dereference()
Browse files Browse the repository at this point in the history
Adds a missed rcu_dereference() around real_parent.

Signed-off-by: Kees Cook <keescook@chromium.org>
Acked-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Signed-off-by: James Morris <jmorris@namei.org>
  • Loading branch information
kees authored and James Morris committed Dec 12, 2011
1 parent 2053c47 commit bb80d88
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion security/tomoyo/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -1122,7 +1122,7 @@ static inline pid_t tomoyo_sys_getppid(void)
{
pid_t pid;
rcu_read_lock();
pid = task_tgid_vnr(current->real_parent);
pid = task_tgid_vnr(rcu_dereference(current->real_parent));
rcu_read_unlock();
return pid;
}
Expand Down

0 comments on commit bb80d88

Please sign in to comment.