summaryrefslogtreecommitdiff
path: root/fs/proc/array.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/proc/array.c')
-rw-r--r--fs/proc/array.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/proc/array.c b/fs/proc/array.c
index 5be663e5dad1..b380313092bd 100644
--- a/fs/proc/array.c
+++ b/fs/proc/array.c
@@ -164,7 +164,7 @@ static inline char *task_state(struct task_struct *p, char *buffer)
ppid = pid_alive(p) ?
task_tgid_nr_ns(rcu_dereference(p->real_parent), ns) : 0;
tpid = pid_alive(p) && p->ptrace ?
- task_ppid_nr_ns(rcu_dereference(p->parent), ns) : 0;
+ task_pid_nr_ns(rcu_dereference(p->parent), ns) : 0;
buffer += sprintf(buffer,
"State:\t%s\n"
"Tgid:\t%d\n"
@@ -459,8 +459,8 @@ static int do_task_stat(struct task_struct *task, char *buffer, int whole)
}
sid = task_session_nr_ns(task, ns);
+ ppid = task_tgid_nr_ns(task->real_parent, ns);
pgid = task_pgrp_nr_ns(task, ns);
- ppid = task_ppid_nr_ns(task, ns);
unlock_task_sighand(task, &flags);
}