aboutsummaryrefslogtreecommitdiffstats
path: root/man2
diff options
context:
space:
mode:
authorMichael Kerrisk <mtk.manpages@gmail.com>2008-12-03 15:56:16 -0500
committerMichael Kerrisk <mtk.manpages@gmail.com>2008-12-05 22:28:59 -0500
commit97fce6cd66aa34d81437d49c044e0a485e7c88ff (patch)
treeba4f1adfb86a6231901e09f248a4374ac3c6be36 /man2
parentb56905c62bd7e100f473272edf9586b9f19d4b6e (diff)
downloadman-pages-97fce6cd66aa34d81437d49c044e0a485e7c88ff.tar.gz
setsid.2: Rework RETURN VALUE section; add an ERRORS section
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Diffstat (limited to 'man2')
-rw-r--r--man2/setsid.216
1 files changed, 9 insertions, 7 deletions
diff --git a/man2/setsid.2 b/man2/setsid.2
index 15ff35af4c..1417c01691 100644
--- a/man2/setsid.2
+++ b/man2/setsid.2
@@ -26,7 +26,7 @@
.\" tiny changes from a man page by Charles Livingston).
.\" Modified Sun Jul 21 14:45:46 1996 <aeb@cwi.nl>
.\"
-.TH SETSID 2 1994-08-27 "Linux" "Linux Programmer's Manual"
+.TH SETSID 2 2008-12-03 "Linux" "Linux Programmer's Manual"
.SH NAME
setsid \- creates a session and sets the process group ID
.SH SYNOPSIS
@@ -48,14 +48,16 @@ process are set to the PID of the calling process.
The calling process will be the only process in
this new process group and in this new session.
.SH "RETURN VALUE"
-The session ID of the calling process.
-.SH ERRORS
-On error, \-1 is returned, and
+On success, the (new) session ID of the calling process is returned.
+On error,
+.I "(pid_t)\ \-1"
+is returned, and
.I errno
-is set.
-The only error which can happen is
+is set to indicate the error.
+.SH ERRORS
+.TP
.BR EPERM .
-It is returned when the process group ID of any process
+The process group ID of any process
equals the PID of the calling process.
Thus, in particular,
.BR setsid ()