summaryrefslogtreecommitdiff
path: root/libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c
diff options
context:
space:
mode:
authorjoseph <joseph@7b3dc134-2b1b-0410-93df-9e9f96275f8d>2013-09-05 22:41:05 +0000
committerjoseph <joseph@7b3dc134-2b1b-0410-93df-9e9f96275f8d>2013-09-05 22:41:05 +0000
commit2c1d357a5fe5bdc4c9521a9d1af05ba1b5a4c238 (patch)
tree12e23fa555f1432064e8fdeeb063dce798764f50 /libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c
parent0d983ceeeee6bd20ae296d224ca2fd4bf27a47af (diff)
downloadeglibc2-2c1d357a5fe5bdc4c9521a9d1af05ba1b5a4c238.tar.gz
Merge changes between r23795 and r23927 from /fsf/trunk.
git-svn-id: svn://svn.eglibc.org/trunk@23928 7b3dc134-2b1b-0410-93df-9e9f96275f8d
Diffstat (limited to 'libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c')
-rw-r--r--libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c b/libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c
index 8182b2bcd..e9b33f2d8 100644
--- a/libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c
+++ b/libc/sysdeps/ieee754/ldbl-64-128/strtold_l.c
@@ -44,11 +44,13 @@ libc_hidden_proto (STRTOF)
#define SET_MANTISSA(flt, mant) \
do { union ieee854_long_double u; \
u.d = (flt); \
- u.ieee.mantissa0 = 0x8000; \
- u.ieee.mantissa1 = 0; \
- u.ieee.mantissa2 = ((mant) >> 32); \
- u.ieee.mantissa3 = (mant) & 0xffffffff; \
- (flt) = u.d; \
+ u.ieee_nan.mantissa0 = 0; \
+ u.ieee_nan.mantissa1 = 0; \
+ u.ieee_nan.mantissa2 = (mant) >> 32; \
+ u.ieee_nan.mantissa3 = (mant); \
+ if ((u.ieee.mantissa0 | u.ieee.mantissa1 \
+ | u.ieee.mantissa2 | u.ieee.mantissa3) != 0) \
+ (flt) = u.d; \
} while (0)
#include <strtod_l.c>