[Midnightbsd-cvs] src: inet_network.c: Fix off by one error.
laffer1 at midnightbsd.org
laffer1 at midnightbsd.org
Wed Jul 9 23:03:20 EDT 2008
Log Message:
-----------
Fix off by one error.
Modified Files:
--------------
src/contrib/bind9/lib/bind/inet:
inet_network.c (r1.1.1.2 -> r1.2)
-------------- next part --------------
Index: inet_network.c
===================================================================
RCS file: /home/cvs/src/contrib/bind9/lib/bind/inet/inet_network.c,v
retrieving revision 1.1.1.2
retrieving revision 1.2
diff -L contrib/bind9/lib/bind/inet/inet_network.c -L contrib/bind9/lib/bind/inet/inet_network.c -u -r1.1.1.2 -r1.2
--- contrib/bind9/lib/bind/inet/inet_network.c
+++ contrib/bind9/lib/bind/inet/inet_network.c
@@ -84,9 +84,9 @@
}
if (!digit)
return (INADDR_NONE);
+ if (pp >= parts + 4 || val > 0xffU)
+ return (INADDR_NONE);
if (*cp == '.') {
- if (pp >= parts + 4 || val > 0xffU)
- return (INADDR_NONE);
*pp++ = val, cp++;
goto again;
}
More information about the Midnightbsd-cvs
mailing list