.TH getgrgid() "" "" "General Function (libc)"
.PC "Get group file information, by group id"
.B "#include <grp.h>"
\fBstruct group *getgrgid(\fIgid\^\fB);\fR
\fBint \fIgid\^\fB;\fR
.PP
.B getgrgid()
searches file
.B /etc/group
for the first entry with a numerical group id of
.IR gid .
It returns a pointer to the entry if found;
it returns NULL if an error occurs or if the end of file is encountered.
.SH Files
.B /etc/group
.br
.B <grp.h>
.SH "See Also"
.Xr "group," group
.Xr "libc" libc
.br
\*(PX Standard, \(sc9.2.1
.SH Notes
All structures and information returned are
in a static area internal to
.BR getgrgid() .
Therefore,
information from a previous call is overwritten by each
subsequent call.
