diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1998-02-12 02:21:20 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1998-02-12 02:21:20 +0000 |
commit | 6386d0e8f672f8135ed39732705f6b553dbdb21b (patch) | |
tree | 6dc9aa776f7d743c06166db937442a041b07e664 /lib | |
parent | 7a6502bd9864816bb01598069ff5363d441b5fc1 (diff) |
correct bounds check
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libc/net/rcmd.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/net/rcmd.c b/lib/libc/net/rcmd.c index 44e4ad3b5cd..ad701acf0e9 100644 --- a/lib/libc/net/rcmd.c +++ b/lib/libc/net/rcmd.c @@ -34,7 +34,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char *rcsid = "$OpenBSD: rcmd.c,v 1.29 1998/02/12 00:48:09 deraadt Exp $"; +static char *rcsid = "$OpenBSD: rcmd.c,v 1.30 1998/02/12 02:21:19 deraadt Exp $"; #endif /* LIBC_SCCS and not lint */ #include <sys/param.h> @@ -448,7 +448,7 @@ __ivaliduser(hostf, raddrl, luser, ruser) auser = *user ? user : luser; ahost = buf; - if (strlen(ahost) > MAXHOSTNAMELEN) + if (strlen(ahost) >= MAXHOSTNAMELEN) continue; /* |