From: Bruno Haible Date: Sun, 4 Nov 2007 14:00:15 +0000 (+0100) Subject: Fix output of floating-point values with large exponent. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=94f364ffb51a234b3da9126355348621222e5de1;p=pspp Fix output of floating-point values with large exponent. --- diff --git a/ChangeLog b/ChangeLog index 57272542ad..34465ea509 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2007-11-04 Bruno Haible + + * lib/vasnprintf.c (scale10_round_decimal_decoded): Fix shift loop. + 2007-11-04 Bruno Haible * modules/relocatable-prog (Files): Add m4/lib-ld.m4. diff --git a/lib/vasnprintf.c b/lib/vasnprintf.c index 55202cbe8c..17a6046308 100644 --- a/lib/vasnprintf.c +++ b/lib/vasnprintf.c @@ -1151,7 +1151,7 @@ scale10_round_decimal_decoded (int e, mpn_t m, void *memory, int n) size_t count; for (count = m.nlimbs; count > 0; count--) { - accu += (mp_twolimb_t) *sourceptr++ << s; + accu += (mp_twolimb_t) *sourceptr++ << s_bits; *destptr++ = (mp_limb_t) accu; accu = accu >> GMP_LIMB_BITS; }