diff options
author | Maxim Konovalov <maxim@FreeBSD.org> | 2002-10-02 07:02:46 +0000 |
---|---|---|
committer | Maxim Konovalov <maxim@FreeBSD.org> | 2002-10-02 07:02:46 +0000 |
commit | 274a62ea0a485df46e89a7f068f87b3b79fdee66 (patch) | |
tree | c6128ae1402bb90438e4f5fd9cb54ee75148f6ef /libc | |
parent | 1e035ac6d2ef675f6f47043c6d4b2196a83ad6c6 (diff) | |
download | pw-darwin-274a62ea0a485df46e89a7f068f87b3b79fdee66.tar.gz pw-darwin-274a62ea0a485df46e89a7f068f87b3b79fdee66.tar.zst pw-darwin-274a62ea0a485df46e89a7f068f87b3b79fdee66.zip |
Too strict error checking in rev. 1.22 broke pwd_mkdb(8) in NIS
environment. An empty UID and GID are valid there.
Spotted by: rwatson
Diffstat (limited to 'libc')
-rw-r--r-- | libc/gen/pw_scan.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libc/gen/pw_scan.c b/libc/gen/pw_scan.c index 95328a8..3d49aa8 100644 --- a/libc/gen/pw_scan.c +++ b/libc/gen/pw_scan.c @@ -104,7 +104,7 @@ __pw_scan(char *bp, struct passwd *pw, int flags) warnx("%s > max uid value (%lu)", p, ULONG_MAX); return (0); } - if (*ep != '\0' || ep == p) { + if (*ep != '\0') { if (flags & _PWSCAN_WARN) warnx("%s uid is incorrect", p); return (0); @@ -130,7 +130,7 @@ __pw_scan(char *bp, struct passwd *pw, int flags) warnx("%s > max gid value (%lu)", p, ULONG_MAX); return (0); } - if (*ep != '\0' || ep == p) { + if (*ep != '\0') { if (flags & _PWSCAN_WARN) warnx("%s gid is incorrect", p); return (0); |