aboutsummaryrefslogtreecommitdiff
path: root/inet/getnetgrent_r.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@gmail.com>2011-07-06 10:52:31 -0400
committerUlrich Drepper <drepper@gmail.com>2011-07-06 10:52:31 -0400
commit5d4cf042506c290f6f6c62d95ce2ebb56c854a7a (patch)
treebaaada7bde5cc824b9afc964e41b2b1fd35feb13 /inet/getnetgrent_r.c
parent751eb97ef2d281711f47fbef70b59b65f7bc6959 (diff)
downloadglibc-5d4cf042506c290f6f6c62d95ce2ebb56c854a7a.tar
glibc-5d4cf042506c290f6f6c62d95ce2ebb56c854a7a.tar.gz
glibc-5d4cf042506c290f6f6c62d95ce2ebb56c854a7a.tar.bz2
glibc-5d4cf042506c290f6f6c62d95ce2ebb56c854a7a.zip
Fix handling of chained netgroups
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 42045a201d..b588897df1 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;