Commit be814fae authored by Dave Jones's avatar Dave Jones Committed by Linus Torvalds

[PATCH] tracer pid.

Can't remember where this came from, but its been around
for quite a while. Prints the parent (tracer) pid if
its being traced.
parent 9d07a3a1
...@@ -161,7 +161,8 @@ static inline char * task_state(struct task_struct *p, char *buffer) ...@@ -161,7 +161,8 @@ static inline char * task_state(struct task_struct *p, char *buffer)
"Uid:\t%d\t%d\t%d\t%d\n" "Uid:\t%d\t%d\t%d\t%d\n"
"Gid:\t%d\t%d\t%d\t%d\n", "Gid:\t%d\t%d\t%d\t%d\n",
get_task_state(p), p->tgid, get_task_state(p), p->tgid,
p->pid, p->pid ? p->real_parent->pid : 0, 0, p->pid, p->pid ? p->real_parent->pid : 0,
p->pid && p->ptrace ? p->parent->pid : 0,
p->uid, p->euid, p->suid, p->fsuid, p->uid, p->euid, p->suid, p->fsuid,
p->gid, p->egid, p->sgid, p->fsgid); p->gid, p->egid, p->sgid, p->fsgid);
read_unlock(&tasklist_lock); read_unlock(&tasklist_lock);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment