aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--nis/nss_compat/compat-pwd.c5
2 files changed, 9 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 9c4fd63..655c13b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+1999-09-23 Ulrich Drepper <drepper@cygnus.com>
+
+ * nis/nss_compat/compat-pwd.c (internal_getpwuid_r): Set errno in
+ one more case.
+
1999-09-22 Andreas Jaeger <aj@suse.de>
* stdio-common/tstscanf.c (main): Add test case from PR libc/1313
diff --git a/nis/nss_compat/compat-pwd.c b/nis/nss_compat/compat-pwd.c
index 6edc9a8..21529c4 100644
--- a/nis/nss_compat/compat-pwd.c
+++ b/nis/nss_compat/compat-pwd.c
@@ -1451,7 +1451,10 @@ internal_getpwuid_r (uid_t uid, struct passwd *result, ent_t *ent,
buffer[buflen - 1] = '\xff';
p = fgets (buffer, buflen, ent->stream);
if (p == NULL && feof (ent->stream))
- return NSS_STATUS_NOTFOUND;
+ {
+ *errnop = ENOENT;
+ return NSS_STATUS_NOTFOUND;
+ }
if (p == NULL || buffer[buflen - 1] != '\xff')
{
fsetpos (ent->stream, &pos);