From: Mark Andrews Date: Tue, 25 Feb 2003 21:32:07 +0000 (+0000) Subject: 1431. [bug] isc_print_snprintf() "%s" with precision could walk of X-Git-Tag: v9.2.3rc1~104^2~103 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=22a9cd54c072545d13788ceead759911fe8cfe34;p=thirdparty%2Fbind9.git 1431. [bug] isc_print_snprintf() "%s" with precision could walk of end of arguement. [RT #5191] --- diff --git a/CHANGES b/CHANGES index 700242c4c6a..be896830e0b 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,6 @@ +1431. [bug] isc_print_snprintf() "%s" with precision could walk of + end of arguement. [RT #5191] + 1430. [port] linux: IPv6 interface scanning support. 1429. [bug] Prevent the cache getting locked to old servers. diff --git a/lib/isc/print.c b/lib/isc/print.c index 53dc52752a8..d15b434625f 100644 --- a/lib/isc/print.c +++ b/lib/isc/print.c @@ -15,7 +15,7 @@ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: print.c,v 1.22 2001/05/16 00:52:55 gson Exp $ */ +/* $Id: print.c,v 1.23 2003/02/25 21:32:07 marka Exp $ */ #include @@ -350,7 +350,7 @@ isc_print_vsnprintf(char *str, size_t size, const char *format, va_list ap) { n = precision; tp = cp; - while (n != 0 && *tp != '0') + while (n != 0 && *tp != '\0') n--, tp++; length = precision - n; } else {