Handles the group network entries.
Standard C Library (libc.a)
#include <netdb.h>
int setnetgrent_r(NetGroup,ptr)
char *NetGroup;
void **ptr;
The setnetgrent_r subroutine functions the same as the setnetgrent subroutine.
The setnetgrent_r subroutine establishes the network group from which the getnetgrent_r subroutine will obtain members. This subroutine also restarts calls to the getnetgrent_r subroutine from the beginnning of the list. If the previous setnetgrent_r call was to a different network group, an endnetgrent_r call is implied. The endnetgrent_r subroutine frees the space allocated during the getnetgrent_r calls.
Item | Description |
---|---|
NetGroup | Points to a network group. |
ptr | Keeps the function threadsafe. |
The setnetgrent_r subroutine returns a 0 if successful and a -1 if unsuccessful.
Item | Description |
---|---|
/etc/netgroup | Contains network groups recognized by the system. |
/usr/include/netdb.h | Contains the network database structures. |