diff --git a/lib/libc/net/inet_network.c b/lib/libc/net/inet_network.c index fda53b6ecc61..c3a96a64e54e 100644 --- a/lib/libc/net/inet_network.c +++ b/lib/libc/net/inet_network.c @@ -74,7 +74,7 @@ again: break; } if (*cp == '.') { - if (pp >= parts + 4) + if (pp >= parts + 3) return (INADDR_NONE); *pp++ = val, cp++; goto again; @@ -83,8 +83,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;