From: Karel Zak Date: Tue, 10 Oct 2017 10:06:09 +0000 (+0200) Subject: setsid: document fork(2) usage X-Git-Tag: v2.31~30 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1f06d754be70b500fd88b0b3b1e0d2c8877f7b09;p=thirdparty%2Futil-linux.git setsid: document fork(2) usage Addresses: https://github.com/karelzak/util-linux/issues/518 Signed-off-by: Karel Zak --- diff --git a/Documentation/TODO b/Documentation/TODO index f81030c151..aab16afb07 100644 --- a/Documentation/TODO +++ b/Documentation/TODO @@ -45,6 +45,11 @@ cleanup lib/path.c: to /sys snapshots (e.g. lsblk regression tests) +setsid +------ + - add --fork to always call fork(2) before setsid(2) + https://github.com/karelzak/util-linux/issues/518 + lscpu ----- - read cpuid and uname information from file if --sysroot is specified, then diff --git a/sys-utils/setsid.1 b/sys-utils/setsid.1 index 67c4208a7c..61b13ce1db 100644 --- a/sys-utils/setsid.1 +++ b/sys-utils/setsid.1 @@ -10,7 +10,10 @@ setsid \- run a program in a new session .RI [ arguments ] .SH DESCRIPTION .B setsid -runs a program in a new session. +runs a program in a new session. The command calls +.BR fork (2) +if already a process group leader. Otherwise, it executes a program in the +current process. .SH OPTIONS .TP .BR \-c , " \-\-ctty"