Annotation of 43BSDTahoe/man/man2/getgroups.2, revision 1.1.1.1

1.1       root        1: .\" Copyright (c) 1983 Regents of the University of California.
                      2: .\" All rights reserved.  The Berkeley software License Agreement
                      3: .\" specifies the terms and conditions for redistribution.
                      4: .\"
                      5: .\"    @(#)getgroups.2 6.4 (Berkeley) 4/10/87
                      6: .\"
                      7: .TH GETGROUPS 2 "April 10, 1987"
                      8: .UC 5
                      9: .SH NAME
                     10: getgroups \- get group access list
                     11: .SH SYNOPSIS
                     12: .nf
                     13: .ft B
                     14: #include <sys/param.h>
                     15: .PP
                     16: .ft B
                     17: ngroups = getgroups(gidsetlen, gidset)
                     18: int ngroups, gidsetlen, *gidset;
                     19: .fi
                     20: .SH DESCRIPTION
                     21: .I Getgroups
                     22: gets the current group access list of the user process
                     23: and stores it in the array 
                     24: .IR gidset .
                     25: The parameter
                     26: .I gidsetlen
                     27: indicates the number of entries that may be placed in 
                     28: .IR gidset.
                     29: .I Getgroups
                     30: returns the actual number of groups returned in
                     31: .IR gidset .
                     32: No more than NGROUPS, as defined in
                     33: .RI < sys/param.h >,
                     34: will ever
                     35: be returned.
                     36: .SH "RETURN VALUE
                     37: A successful call returns the number of groups in the group set.
                     38: A value of \-1 indicates that an error occurred, and the error
                     39: code is stored in the global variable \fIerrno\fP\|.
                     40: .SH "ERRORS
                     41: The possible errors for \fIgetgroup\fP are:
                     42: .TP 15
                     43: [EINVAL]
                     44: The argument
                     45: .I gidsetlen
                     46: is smaller than the number of groups in the group set.
                     47: .TP
                     48: [EFAULT]
                     49: The argument \fIgidset\fP specifies
                     50: an invalid address.
                     51: .SH "SEE ALSO
                     52: setgroups(2), initgroups(3)
                     53: .SH BUGS
                     54: The
                     55: .I gidset
                     56: array should be of type
                     57: .BR gid_t ,
                     58: but remains integer for compatibility with earlier systems.

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.