_exit.2: On exit, child processes may be inherited by a "subreaper"

It is no longer necessarily true that orphaned processes
are inherited by PID 1.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2017-03-15 12:39:23 +01:00
parent 55873ed61c
commit 99ed723adc
1 changed files with 6 additions and 2 deletions

View File

@ -54,8 +54,12 @@ The function
.BR _exit ()
terminates the calling process "immediately".
Any open file descriptors belonging to the process are closed.
Any children of the process are inherited by process 1,
.IR init .
Any children of the process are inherited by
.IR init (1)
(or by the nearest "subreaper" process as defined through the use of the
.BR prctl (2)
.B PR_SET_CHILD_SUBREAPER
operation).
The process's parent is sent a
.B SIGCHLD
signal.