summaryrefslogtreecommitdiff
path: root/lib/libc
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1997-04-13 05:08:25 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1997-04-13 05:08:25 +0000
commitf832b8a3221289d902d377512178d18598b94be1 (patch)
tree9ca96f5ead3a65b8db3317b65cab3b180f1a5c40 /lib/libc
parent249e5581181a54affeb5776f4564761000bec325 (diff)
buf oflow; bitblt
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/net/inet_pton.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/net/inet_pton.c b/lib/libc/net/inet_pton.c
index 8ffe81ed12f..46b4b24819c 100644
--- a/lib/libc/net/inet_pton.c
+++ b/lib/libc/net/inet_pton.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: inet_pton.c,v 1.1 1997/03/13 19:07:33 downsj Exp $ */
+/* $OpenBSD: inet_pton.c,v 1.2 1997/04/13 05:08:24 deraadt Exp $ */
/* Copyright (c) 1996 by Internet Software Consortium.
*
@@ -20,7 +20,7 @@
#if 0
static char rcsid[] = "$From: inet_pton.c,v 8.7 1996/08/05 08:31:35 vixie Exp $";
#else
-static char rcsid[] = "$OpenBSD: inet_pton.c,v 1.1 1997/03/13 19:07:33 downsj Exp $";
+static char rcsid[] = "$OpenBSD: inet_pton.c,v 1.2 1997/04/13 05:08:24 deraadt Exp $";
#endif
#endif /* LIBC_SCCS and not lint */
@@ -100,12 +100,12 @@ inet_pton4(src, dst)
if (new > 255)
return (0);
- *tp = new;
if (! saw_digit) {
if (++octets > 4)
return (0);
saw_digit = 1;
}
+ *tp = new;
} else if (ch == '.' && saw_digit) {
if (octets == 4)
return (0);