mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-28 00:21:52 +03:00
Update.
2004-03-24 Jakub Jelinek <jakub@redhat.com> * stdlib/strtod_l.c (INTERNAL (__STRTOF)): Clear the rest of retval, not just one limb if RETURN_LIMB_SIZE > 2. Fix shifting up if RETURN_LIMB_SIZE > 2. * stdio-common/printf_fp.c (__printf_fp): For IEEE quad long double on 32-bit architectures reserve 8 limbs instead of 4.
This commit is contained in:
@ -1155,7 +1155,11 @@ INTERNAL (__STRTOF) (nptr, endptr, group, loc)
|
||||
memcpy (retval, num, numsize * sizeof (mp_limb_t));
|
||||
#if RETURN_LIMB_SIZE > 1
|
||||
if (numsize < RETURN_LIMB_SIZE)
|
||||
# if RETURN_LIMB_SIZE == 2
|
||||
retval[numsize] = 0;
|
||||
# else
|
||||
MPN_ZERO (retval + numsize, RETURN_LIMB_SIZE - numsize);
|
||||
# endif
|
||||
#endif
|
||||
}
|
||||
|
||||
@ -1461,8 +1465,10 @@ INTERNAL (__STRTOF) (nptr, endptr, group, loc)
|
||||
__mpn_lshift_1 (retval, RETURN_LIMB_SIZE,
|
||||
BITS_PER_MP_LIMB, 0);
|
||||
#else
|
||||
for (i = RETURN_LIMB_SIZE; i > empty; --i)
|
||||
for (i = RETURN_LIMB_SIZE - 1; i >= empty; --i)
|
||||
retval[i] = retval[i - empty];
|
||||
while (i >= 0)
|
||||
retval[i--] = 0;
|
||||
#endif
|
||||
for (i = numsize; i > 0; --i)
|
||||
num[i + empty] = num[i - 1];
|
||||
|
Reference in New Issue
Block a user