diff options
Diffstat (limited to 'stdlib/strtof_l.c')
-rw-r--r-- | stdlib/strtof_l.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/stdlib/strtof_l.c b/stdlib/strtof_l.c index 6fb44bd403..c4c1c1f2dd 100644 --- a/stdlib/strtof_l.c +++ b/stdlib/strtof_l.c @@ -37,10 +37,9 @@ extern unsigned long long int ____strtoull_l_internal (const char *, char **, #define SET_MANTISSA(flt, mant) \ do { union ieee754_float u; \ u.f = (flt); \ - if ((mant & 0x7fffff) == 0) \ - mant = 0x400000; \ - u.ieee.mantissa = (mant) & 0x7fffff; \ - (flt) = u.f; \ + u.ieee_nan.mantissa = (mant); \ + if (u.ieee.mantissa != 0) \ + (flt) = u.f; \ } while (0) #include "strtod_l.c" |