GETGROUPS(2) | System Calls Manual | GETGROUPS(2) |
getgroups
—
#include <unistd.h>
int
getgroups
(int
gidsetlen, gid_t
*gidset);
getgroups
() gets the current group access list of the
current user process and stores it in the array gidset.
The parameter gidsetlen indicates the number of entries
that may be placed in gidset.
getgroups
() returns the actual number of groups
returned in gidset. No more than
{NGROUPS_MAX
} will ever be returned. If
gidsetlen is 0, getgroups
()
returns the number of groups without modifying the
gidset array.
This system call only returns the secondary groups.
getgroups
() are:
getgroups
() function conforms to
IEEE Std 1003.1-1990 (“POSIX.1”).
getgroups
() function call appeared in
4.2BSD.
October 7, 2006 | NetBSD 9.2 |