getpgrp actually takes void. ask the IEEE...

This commit is contained in:
cgd 1993-05-16 01:51:51 +00:00
parent fe0ee6d526
commit f9350c73f0
4 changed files with 19 additions and 8 deletions

View File

@ -80,7 +80,7 @@ uid_t geteuid __P((void));
gid_t getgid __P((void));
int getgroups __P((int, int *)); /* XXX (gid_t *) */
char *getlogin __P((void));
pid_t getpgrp __P((int));
pid_t getpgrp __P((void));
pid_t getpid __P((void));
pid_t getppid __P((void));
uid_t getuid __P((void));

View File

@ -38,14 +38,12 @@
.Nm getpgrp
.Nd get process group
.Sh SYNOPSIS
.Fd #include <unistd.h>
.Ft pid_t
.Fn getpgrp "int pid"
.Fn getpgrp "void"
.Sh DESCRIPTION
The process group of the specified process is returned by
The process group of the current process is returned by
.Fn getpgrp .
If
.Fa pid
is zero, the call applies to the current process.
.Pp
Process groups are used for distribution of signals, and
by terminals to arbitrate requests for their input: processes
@ -75,3 +73,16 @@ The
.Nm
function call appeared in
.Bx 4.0 .
.Sh STANDARDS
The
.Fn getpgrp
function conforms to IEEE Std 1003.1-1988
.Pq Dq Tn POSIX .
.Sh COMPATABILITY
This version of
.Fn getpgrp
differs from past Berkeley versions by not taking a
.Fa "pid_t pid"
argument.
This incompatibility is required by
.St -p1003.1-88 .

View File

@ -305,7 +305,7 @@ struct sysent sysent[] = {
3, mincore, /* 78 = mincore */
2, getgroups, /* 79 = getgroups */
2, setgroups, /* 80 = setgroups */
1, getpgrp, /* 81 = getpgrp */
0, getpgrp, /* 81 = getpgrp */
2, setpgid, /* 82 = setpgid */
3, setitimer, /* 83 = setitimer */
compat(0,wait), /* 84 = old wait */

View File

@ -114,7 +114,7 @@
78 STD 3 mincore
79 STD 2 getgroups
80 STD 2 setgroups
81 STD 1 getpgrp
81 STD 0 getpgrp
82 STD 2 setpgid
83 STD 3 setitimer
84 COMPAT 0 wait