From: Rich Felker Date: Wed, 11 Apr 2012 03:41:54 +0000 (-0400) Subject: fix float scanning of certain values ending in zeros X-Git-Url: http://nsz.repo.hu/git/?p=musl;a=commitdiff_plain;h=38b3f1fea8fe4f2c590c1a9438d219291a7bfcd2 fix float scanning of certain values ending in zeros for example, "1000000000" was being read as "1" due to this loop exiting early. it's necessary to actually update z and zero the entries so that the subsequent rounding code does not get confused; before i did that, spurious inexact exceptions were being raised. --- diff --git a/src/internal/floatscan.c b/src/internal/floatscan.c index ed735278..000706d7 100644 --- a/src/internal/floatscan.c +++ b/src/internal/floatscan.c @@ -225,8 +225,10 @@ static long double decfloat(FILE *f, int bits, int emin, int sign, int pok) } } - for (y=i=0; i