1group_member(3)            Library Functions Manual            group_member(3)
2
3
4

NAME

6       group_member - test whether a process is in a group
7

LIBRARY

9       Standard C library (libc, -lc)
10

SYNOPSIS

12       #include <unistd.h>
13
14       int group_member(gid_t gid);
15
16   Feature Test Macro Requirements for glibc (see feature_test_macros(7)):
17
18       group_member():
19           _GNU_SOURCE
20

DESCRIPTION

22       The  group_member()  function tests whether any of the caller's supple‐
23       mentary group IDs (as returned by getgroups(2)) matches gid.
24

RETURN VALUE

26       The group_member() function returns nonzero if any of the caller's sup‐
27       plementary group IDs matches gid, and zero otherwise.
28

STANDARDS

30       GNU.
31

SEE ALSO

33       getgid(2), getgroups(2), getgrouplist(3), group(5)
34
35
36
37Linux man-pages 6.04              2023-03-30                   group_member(3)
Impressum