]> Git Repo - linux.git/commit
wait: swap EXIT_ZOMBIE and EXIT_DEAD to hide EXIT_TRACE from user-space
authorOleg Nesterov <[email protected]>
Mon, 7 Apr 2014 22:38:46 +0000 (15:38 -0700)
committerLinus Torvalds <[email protected]>
Mon, 7 Apr 2014 23:36:06 +0000 (16:36 -0700)
commitad86622b478eaafdc25b74237df82b10fce6326d
tree5cec0d87c13edce3c73a087903801492362310cd
parentb3ab03160dfaf8ab78d476b670de319f4c1a5685
wait: swap EXIT_ZOMBIE and EXIT_DEAD to hide EXIT_TRACE from user-space

get_task_state() uses the most significant bit to report the state to
user-space, this means that EXIT_ZOMBIE->EXIT_TRACE->EXIT_DEAD transition
can be noticed via /proc as Z -> X -> Z change.  Note that this was
possible even before EXIT_TRACE was introduced.

This is not really bad but imho it make sense to hide EXIT_TRACE from
user-space completely.  So the patch simply swaps EXIT_ZOMBIE and
EXIT_DEAD, this way EXIT_TRACE will be seen as EXIT_ZOMBIE by user-space.

Signed-off-by: Oleg Nesterov <[email protected]>
Cc: Jan Kratochvil <[email protected]>
Cc: Michal Schmidt <[email protected]>
Cc: Al Viro <[email protected]>
Cc: Lennart Poettering <[email protected]>
Cc: Roland McGrath <[email protected]>
Cc: Tejun Heo <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
fs/proc/array.c
include/linux/sched.h
This page took 0.053861 seconds and 4 git commands to generate.