r2101 - in glibc-package/trunk/debian: . patches/any
Author: aurel32
Date: 2007-04-20 16:50:14 +0000 (Fri, 20 Apr 2007)
New Revision: 2101
Modified:
glibc-package/trunk/debian/changelog
glibc-package/trunk/debian/patches/any/cvs-printf_fp-c.diff
Log:
* patches/any/cvs-printf_fp-c.diff: update patch from CVS (fix exponent
-4 special case handling when wcp == wstartp + 1). Closes: #419225.
Modified: glibc-package/trunk/debian/changelog
===================================================================
--- glibc-package/trunk/debian/changelog 2007-04-19 23:13:33 UTC (rev 2100)
+++ glibc-package/trunk/debian/changelog 2007-04-20 16:50:14 UTC (rev 2101)
@@ -8,9 +8,13 @@
/var/lib/dpkg/info. Thanks to Guillem Jover for the hint.
* patches/mips/cvs-ldsodefs_h.diff: new patch (correct multiple
inclusion guard in sysdeps/mips/ldsodefs.h) from CVS.
+ * patches/any/cvs-printf_fp-c.diff: update patch from CVS (fix exponent
+ -4 special case handling when wcp == wstartp + 1). Closes: #419225.
- -- Aurelien Jarno <aurel32@debian.org> Fri, 20 Apr 2007 01:12:25 +0200
+
+ -- Aurelien Jarno <aurel32@debian.org> Fri, 20 Apr 2007 18:49:30 +0200
+
glibc (2.5-3) unstable; urgency=low
[ Pierre Habouzit ]
Modified: glibc-package/trunk/debian/patches/any/cvs-printf_fp-c.diff
===================================================================
--- glibc-package/trunk/debian/patches/any/cvs-printf_fp-c.diff 2007-04-19 23:13:33 UTC (rev 2100)
+++ glibc-package/trunk/debian/patches/any/cvs-printf_fp-c.diff 2007-04-20 16:50:14 UTC (rev 2101)
@@ -105,7 +105,7 @@
{
--wcp;
--fracdig_no;
-@@ -1060,26 +1076,41 @@
+@@ -1060,26 +1076,46 @@
/* Write the exponent if it is needed. */
if (type != 'f')
{
@@ -125,12 +125,17 @@
+ /* This is another special case. The exponent of the number is
+ really smaller than -4, which requires the 'e'/'E' format.
+ But after rounding the number has an exponent of -4. */
-+ assert (wcp >= wstartp + 2);
++ assert (wcp >= wstartp + 1);
+ assert (wstartp[0] == L'1');
+ __wmemcpy (wstartp, L"0.0001", 6);
+ wstartp[1] = decimalwc;
-+ wmemset (wstartp + 6, L'0', wcp - (wstartp + 2));
-+ wcp += 4;
++ if (wcp >= wstartp + 2)
++ {
++ wmemset (wstartp + 6, L'0', wcp - (wstartp + 2));
++ wcp += 4;
++ }
++ else
++ wcp += 5;
+ }
else
- do
@@ -166,7 +171,7 @@
}
/* Compute number of characters which must be filled with the padding
-@@ -1120,15 +1151,14 @@
+@@ -1120,15 +1156,14 @@
else
thousands_sep_len = strlen (thousands_sep);
@@ -184,7 +189,7 @@
return -1;
}
}
-@@ -1162,7 +1192,7 @@
+@@ -1162,7 +1197,7 @@
PRINT (tmpptr, wstartp, wide ? wcp - wstartp : cp - tmpptr);
/* Free the memory if necessary. */
@@ -193,26 +198,3 @@
{
free (buffer);
free (wbuffer);
---- libc/stdio-common/printf_fp.c.jj 2007-02-26 18:13:47.000000000 +0100
-+++ libc/stdio-common/printf_fp.c 2007-04-13 16:03:38.000000000 +0200
-@@ -1081,12 +1081,18 @@
- /* This is another special case. The exponent of the number is
- really smaller than -4, which requires the 'e'/'E' format.
- But after rounding the number has an exponent of -4. */
-- assert (wcp >= wstartp + 2);
-+ assert (wcp >= wstartp + 1);
- assert (wstartp[0] == L'1');
- __wmemcpy (wstartp, L"0.0001", 6);
- wstartp[1] = decimalwc;
- wmemset (wstartp + 6, L'0', wcp - (wstartp + 2));
-- wcp += 4;
-+ if (wcp >= wstartp + 2)
-+ {
-+ wmemset (wstartp + 6, L'0', wcp - (wstartp + 2));
-+ wcp += 4;
-+ }
-+ else
-+ wcp += 5;
- }
- else
- {
Reply to: