summary refs log tree commit diff
path: root/stdlib/strtod_l.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-07-25 03:31:54 +0000
committerUlrich Drepper <drepper@redhat.com>2004-07-25 03:31:54 +0000
commitdeddf8092de80946261279dd9669a801c24aad81 (patch)
treebaf9e282f473865d7d24d38434a1dadd2c138818 /stdlib/strtod_l.c
parent15ef4b555f5bef9bbcb39bf72f8399d77e57afff (diff)
downloadglibc-deddf8092de80946261279dd9669a801c24aad81.tar.gz
glibc-deddf8092de80946261279dd9669a801c24aad81.tar.xz
glibc-deddf8092de80946261279dd9669a801c24aad81.zip
[BZ #274]
Update.
2004-07-21  Jakub Jelinek  <jakub@redhat.com>

	[BZ #274]
	* stdlib/strtod_l.c (INTERNAL (__STRTOF)): Fix used >=
	BITS_PER_MP_LIMB shifting up.
	* stdlib/tst-strtod.c (main): Add new tests.
Diffstat (limited to 'stdlib/strtod_l.c')
-rw-r--r--stdlib/strtod_l.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/stdlib/strtod_l.c b/stdlib/strtod_l.c
index 9eca802a10..dce65cb83c 100644
--- a/stdlib/strtod_l.c
+++ b/stdlib/strtod_l.c
@@ -1484,7 +1484,7 @@ INTERNAL (__STRTOF) (nptr, endptr, group, loc)
 						       / BITS_PER_MP_LIMB],
 					       retval, RETURN_LIMB_SIZE,
 					       used % BITS_PER_MP_LIMB);
-			  for (i = used / BITS_PER_MP_LIMB; i >= 0; --i)
+			  for (i = used / BITS_PER_MP_LIMB - 1; i >= 0; --i)
 			    retval[i] = 0;
 			}
 		      else if (used > 0)