aboutsummaryrefslogtreecommitdiffstats
path: root/man2
diff options
context:
space:
mode:
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 ()