From: hniksic Date: Sat, 25 Jun 2005 20:50:42 +0000 (-0700) Subject: [svn] Decrease buffer size of with_thousand_seps_sum. X-Git-Tag: v1.13~908 X-Git-Url: http://sjero.net/git/?p=wget;a=commitdiff_plain;h=d92cf8d560a37ea48ddbd02e501fc6a9633db5c5 [svn] Decrease buffer size of with_thousand_seps_sum. --- diff --git a/src/ChangeLog b/src/ChangeLog index 904d85a5..bce65f62 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2005-06-25 Hrvoje Niksic + + * utils.c (with_thousand_seps_sum): Decrease buffer size so it + cannot overrun add_thousand_seps's buffer. + 2005-06-25 Hrvoje Niksic * utils.c (SPRINTF_WGINT): The correct format is %I64d, not just diff --git a/src/utils.c b/src/utils.c index d0d7fbc9..a2942b37 100644 --- a/src/utils.c +++ b/src/utils.c @@ -1221,7 +1221,7 @@ with_thousand_seps (wgint l) char * with_thousand_seps_sum (SUM_SIZE_INT l) { - char inbuf[64]; + char inbuf[32]; snprintf (inbuf, sizeof (inbuf), "%.0f", l); return add_thousand_seps (inbuf); }