aboutsummaryrefslogtreecommitdiff
path: root/inet/getnetgrent_r.c
diff options
context:
space:
mode:
Diffstat (limited to 'inet/getnetgrent_r.c')
-rw-r--r--inet/getnetgrent_r.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/inet/getnetgrent_r.c b/inet/getnetgrent_r.c
index 42045a2..b588897 100644
--- a/inet/getnetgrent_r.c
+++ b/inet/getnetgrent_r.c
@@ -279,6 +279,11 @@ internal_getnetgrent_r (char **hostp, char **userp, char **domainp,
namep = namep->next)
if (strcmp (datap->val.group, namep->name) == 0)
break;
+ if (namep == NULL)
+ for (namep = datap->needed_groups; namep != NULL;
+ namep = namep->next)
+ if (strcmp (datap->val.group, namep->name) == 0)
+ break
if (namep != NULL)
/* Really ignore. */
continue;