summaryrefslogtreecommitdiffstats
path: root/lib/libc
diff options
context:
space:
mode:
authorbsd <bsd@FreeBSD.org>2000-03-16 23:53:41 +0000
committerbsd <bsd@FreeBSD.org>2000-03-16 23:53:41 +0000
commitc1a1c736a75b08b88b083b78e5ca96c026d8e20a (patch)
treed30d649c0cbe2dda94c725c53c776e35691b803b /lib/libc
parentbf05d34440bf23f33f292b6ea372b496706ef652 (diff)
downloadFreeBSD-src-c1a1c736a75b08b88b083b78e5ca96c026d8e20a.zip
FreeBSD-src-c1a1c736a75b08b88b083b78e5ca96c026d8e20a.tar.gz
Back out that last commit, it may be insecure (pointed out by Warner
Losh).
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/net/rcmd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/net/rcmd.c b/lib/libc/net/rcmd.c
index af8fc30..5bbef4b 100644
--- a/lib/libc/net/rcmd.c
+++ b/lib/libc/net/rcmd.c
@@ -562,7 +562,7 @@ __ivaliduser_af(hostf, raddr, luser, ruser, af, len)
while (fgets(buf, sizeof(buf), hostf)) {
p = buf;
/* Skip lines that are too long. */
- if (strchr(p, '\n') == NULL && !feof(hostf)) {
+ if (strchr(p, '\n') == NULL) {
while ((ch = getc(hostf)) != '\n' && ch != EOF);
continue;
}
OpenPOWER on IntegriCloud