summary refs log tree commit diff
path: root/nis
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2004-12-13 23:32:37 +0000
committerJakub Jelinek <jakub@redhat.com>2004-12-13 23:32:37 +0000
commitf9626feb2d8a692e27d1c020beba198ec52a705a (patch)
tree80e2799fe980f5c79a6bce099548081def04da41 /nis
parente797f2e35cbf7edf2c7de7f79442bda550917f07 (diff)
downloadglibc-f9626feb2d8a692e27d1c020beba198ec52a705a.tar.gz
glibc-f9626feb2d8a692e27d1c020beba198ec52a705a.tar.xz
glibc-f9626feb2d8a692e27d1c020beba198ec52a705a.zip
Updated to fedora-glibc-20041213T2323 cvs/fedora-glibc-2_3_3-91
Diffstat (limited to 'nis')
-rw-r--r--nis/nss_nisplus/nisplus-netgrp.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/nis/nss_nisplus/nisplus-netgrp.c b/nis/nss_nisplus/nisplus-netgrp.c
index c56a6854a4..607bc2c1ca 100644
--- a/nis/nss_nisplus/nisplus-netgrp.c
+++ b/nis/nss_nisplus/nisplus-netgrp.c
@@ -88,7 +88,9 @@ _nss_nisplus_getnetgrent_r (struct __netgrent *result, char *buffer,
 
       result->type = triple_val;
 
-      if (hostlen == 0)
+      if (hostlen == 0 ||
+	  NISENTRYVAL (result->position, 2,
+		       (nis_result *) result->data)[0] == '\0')
 	result->val.triple.host = NULL;
       else
 	{
@@ -99,7 +101,9 @@ _nss_nisplus_getnetgrent_r (struct __netgrent *result, char *buffer,
 	  *cp++ = '\0';
 	}
 
-      if (userlen == 0)
+      if (userlen == 0 ||
+	  NISENTRYVAL (result->position, 3,
+		       (nis_result *) result->data)[0] == '\0')
 	result->val.triple.user = NULL;
       else
 	{
@@ -110,7 +114,9 @@ _nss_nisplus_getnetgrent_r (struct __netgrent *result, char *buffer,
 	  *cp++ = '\0';
 	}
 
-      if (domainlen == 0)
+      if (domainlen == 0 ||
+	  NISENTRYVAL (result->position, 4,
+		       (nis_result *) result->data)[0] == '\0')
 	result->val.triple.domain = NULL;
       else
 	{