summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1997-08-19 07:00:53 +0000
committerpeter <peter@FreeBSD.org>1997-08-19 07:00:53 +0000
commit4ca1f3fe2ff8665fdf0ee06ab7e377996a5054e0 (patch)
treef5562552b984b949f1f3e19bcd62575ec9930738
parent1f58fa1ad3c6ffe0bb1ddd698c4964703ed43947 (diff)
downloadFreeBSD-src-4ca1f3fe2ff8665fdf0ee06ab7e377996a5054e0.zip
FreeBSD-src-4ca1f3fe2ff8665fdf0ee06ab7e377996a5054e0.tar.gz
Manpage for getpgid(2), wording taken from NetBSD.
-rw-r--r--lib/libc/sys/Makefile.inc3
-rw-r--r--lib/libc/sys/getpgrp.217
2 files changed, 17 insertions, 3 deletions
diff --git a/lib/libc/sys/Makefile.inc b/lib/libc/sys/Makefile.inc
index e024bcb..60056df 100644
--- a/lib/libc/sys/Makefile.inc
+++ b/lib/libc/sys/Makefile.inc
@@ -1,5 +1,5 @@
# @(#)Makefile.inc 8.3 (Berkeley) 10/24/94
-# $Id: Makefile.inc,v 1.34 1997/06/01 09:47:06 peter Exp $
+# $Id: Makefile.inc,v 1.35 1997/08/19 06:23:45 peter Exp $
# sys sources
.PATH: ${.CURDIR}/../libc/${MACHINE}/sys ${.CURDIR}/../libc/sys
@@ -129,6 +129,7 @@ MLINKS+=clock_gettime.2 clock_settime.2 clock_gettime.2 clock_getres.2
MLINKS+=getgid.2 getegid.2
MLINKS+=getitimer.2 setitimer.2
MLINKS+=getlogin.2 setlogin.2
+MLINKS+=getpgrp.2 getpgid.2
MLINKS+=getpid.2 getppid.2
MLINKS+=getpriority.2 setpriority.2
MLINKS+=getrlimit.2 setrlimit.2
diff --git a/lib/libc/sys/getpgrp.2 b/lib/libc/sys/getpgrp.2
index 9780b19..6e9d1e4 100644
--- a/lib/libc/sys/getpgrp.2
+++ b/lib/libc/sys/getpgrp.2
@@ -41,9 +41,15 @@
.Fd #include <unistd.h>
.Ft pid_t
.Fn getpgrp "void"
+.Ft pid_t
+.Fn getpgid "pid_t pid"
.Sh DESCRIPTION
The process group of the current process is returned by
.Fn getpgrp .
+The process group of the process identified by
+.Fa pid
+is returned by
+.Fn getpgid .
.Pp
Process groups are used for distribution of signals, and
by terminals to arbitrate requests for their input: processes
@@ -64,12 +70,16 @@ calls
are used to get/set the process group of the control terminal.
.Sh SEE ALSO
.Xr setpgid 2 ,
+.Xr getsid 2 ,
.Xr termios 4
.Sh HISTORY
The
.Fn getpgrp
function call appeared in
.Bx 4.0 .
+The
+.Fn getpgid
+function call is derived from it's usage in System V Release 4.
.Sh STANDARDS
The
.Fn getpgrp
@@ -82,10 +92,10 @@ differs from past Berkeley versions by not taking a
.Fa "pid_t pid"
argument.
This incompatibility is required by
-.St -p1003.1-88 .
+.St -p1003.1-90 .
.Pp
From the
-.St -p1003.1-88
+.St -p1003.1-90
Rationale:
.Pp
.Bx 4.3
@@ -102,3 +112,6 @@ suffices, and the added complexity of the
.Bx 4.3
.Fn getpgrp
has been omitted from POSIX.1.
+The old functionality is available from the
+.Fn getpgid
+function.
OpenPOWER on IntegriCloud