Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!burl!ulysses!harpo!seismo!hao!hplabs!sri-unix!craig@Bbn-Unix.ARPA From: craig@Bbn-Unix.ARPA Newsgroups: net.unix-wizards Subject: 4.2 getgroups manual page Message-ID: <12229@sri-arpa.UUCP> Date: Thu, 12-Apr-84 14:02:52 EST Article-I.D.: sri-arpa.12229 Posted: Thu Apr 12 14:02:52 1984 Date-Received: Tue, 17-Apr-84 07:39:59 EST Lines: 53 From: Craig Partridge (My mailer tells me this letter died en-route, so I'll try again.) The manual page for getgroups() on 4.2 is very wrong (both Sun and Berkeley manuals). A correct version is below. Corrections include: argument types, return value, constant name and additional error codes. ____________________________________________________________________ .TH GETGROUPS 2 "7 July 1983" .UC 4 .SH NAME getgroups \- get group access list .SH SYNOPSIS .nf .ft B #include .PP .ft B ngrps = getgroups(gsize, gidset) int ngrps, gsize, *gidset; .fi .SH DESCRIPTION .I Getgroups gets the current group access list of the user process and stores it in the array .IR gidset . The parameter .I gsize indicates the number of entries which may be placed in .I gidset . The return value is the number of entries in .I gidset that were filled. No more than NGROUPS, as defined in .RI < sys/param.h >, will ever be returned. .SH "RETURN VALUE A value of \-1 indicates that an error occurred, and the error code is stored in the global variable \fIerrno\fP\|. .SH "ERRORS The possible errors for \fIgetgroups\fP are: .TP 15 [EFAULT] The argument \fIgidset\fP is an invalid address. .TP 15 [EINVAL] The size of \fIgidset\fP as specified by \fIgsize\fP is too small to accomodate the entire group access list. .SH "SEE ALSO setgroups(2), initgroups(3)