INITGROUPS(3,L) AIX Technical Reference INITGROUPS(3,L) ------------------------------------------------------------------------------- initgroups PURPOSE Initializes group access list. LIBRARY Standard C Library (libc.a) SYNTAX int initgroups (user, basegid) char *user; int basegid; DESCRIPTION The initgroups subroutine reads the /etc/group file and constructs the group access list for the user whose name is specified by the user parameter. The basegid parameter is usually the group number from the /etc/passwd file and it is automatically included in the group list. Warning: The initgroups subroutine uses the getgrent subroutine family. If the program that invokes initgroups uses any of these subroutines, then calling initgroups overwrites the static group structure. RETURN VALUE Upon successful completion, the initgroups subroutine returns a value of 0. If the effective user ID of the calling process is not superuser, then initgroups returns a value of 1. FILE /etc/group RELATED INFORMATION In this book: "getgrent, getgrgid, getgrnam, setgrent, endgrent," "getgroups," and "setgroups." The adduser command in AIX Operating System Commands Reference. Processed November 7, 1990 INITGROUPS(3,L) 1