summaryrefslogtreecommitdiff
path: root/lib/libc/net/inet_network.c
diff options
context:
space:
mode:
authorNiklas Hallqvist <niklas@cvs.openbsd.org>1996-03-19 23:15:57 +0000
committerNiklas Hallqvist <niklas@cvs.openbsd.org>1996-03-19 23:15:57 +0000
commite46701f3ba417eb809e480d2383217567bd8a0d3 (patch)
tree6418b00c595e11941ebeb3d312e0136cfb1621b8 /lib/libc/net/inet_network.c
parent169c29d1b708c51bbae3f546e0adfe0d433b5b7b (diff)
From NetBSD: merge of 960317
Diffstat (limited to 'lib/libc/net/inet_network.c')
-rw-r--r--lib/libc/net/inet_network.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/libc/net/inet_network.c b/lib/libc/net/inet_network.c
index 35105fa75a8..3de21a5bac8 100644
--- a/lib/libc/net/inet_network.c
+++ b/lib/libc/net/inet_network.c
@@ -1,4 +1,5 @@
-/* $NetBSD: inet_network.c,v 1.4 1995/02/25 06:20:45 cgd Exp $ */
+/* $OpenBSD: inet_network.c,v 1.2 1996/03/19 23:15:08 niklas Exp $ */
+/* $NetBSD: inet_network.c,v 1.5 1996/02/17 15:35:41 hpeyerl Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -37,7 +38,8 @@
#if 0
static char sccsid[] = "@(#)inet_network.c 8.1 (Berkeley) 6/4/93";
#else
-static char rcsid[] = "$NetBSD: inet_network.c,v 1.4 1995/02/25 06:20:45 cgd Exp $";
+static char rcsid[] = "$OpenBSD: inet_network.c,v 1.2 1996/03/19 23:15:08 niklas Exp $";
+static char rcsid[] = "$NetBSD: inet_network.c,v 1.5 1996/02/17 15:35:41 hpeyerl Exp $";
#endif
#endif /* LIBC_SCCS and not lint */
@@ -80,7 +82,7 @@ again:
break;
}
if (*cp == '.') {
- if (pp >= parts + 4)
+ if (pp >= parts + 3)
return (INADDR_NONE);
*pp++ = val, cp++;
goto again;
@@ -89,8 +91,6 @@ again:
return (INADDR_NONE);
*pp++ = val;
n = pp - parts;
- if (n > 4)
- return (INADDR_NONE);
for (val = 0, i = 0; i < n; i++) {
val <<= 8;
val |= parts[i] & 0xff;