HomeFreeBSD

Fix an infinite loop in setnetgrent(3) with NIS netgroups.

Description

Fix an infinite loop in setnetgrent(3) with NIS netgroups.

Handle an empty result from yp_match() by returning NULL, which is
consistent with the handling of an empty netgroup in /etc/netgroup.
setnetgrent(3) has no return value, so there is no particular need to
distinguish this case from an error.

PR: 26486
MFC after: 2 weeks

Details

Provenance
markjAuthored on
Parents
rS301709: Use a more common spelling for "(char *)0" in the getnetgrent man page.
Branches
Unknown
Tags
Unknown