]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Update.
authorUlrich Drepper <drepper@redhat.com>
Tue, 10 Feb 2004 08:02:07 +0000 (08:02 +0000)
committerUlrich Drepper <drepper@redhat.com>
Tue, 10 Feb 2004 08:02:07 +0000 (08:02 +0000)
2004-02-10  Ulrich Drepper  <drepper@redhat.com>

* stdio-common/_i18n_number.h: Finish last patch.

ChangeLog
stdio-common/_i18n_number.h

index 6cd6fb2733e6cd718879bc91eb9f74cb48519c00..074192afaf00ea6dac32a5c71a5fe3b66c467628 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2004-02-10  Ulrich Drepper  <drepper@redhat.com>
+
+       * stdio-common/_i18n_number.h: Finish last patch.
+
 2004-02-09  Ulrich Drepper  <drepper@redhat.com>
 
        * sysdeps/i386/i686/memcmp.S: New file.  Patch by HJ Lu.
index 0043b044707390e22c021e2995b5055b237a0f85..f3404c5a0a09d13d7b4200ed31c8f141e8c0c62e 100644 (file)
@@ -32,8 +32,8 @@ _i18n_number_rewrite (CHAR_T *w, CHAR_T *rear_ptr)
 # define decimal NULL
 # define thousands NULL
 #else
-# define wdecimal L'\0'
-# define wthousands L'\0'
+  wint_t wdecimal = L'\0';
+  wint_t wthousands = L'\0';
   char decimal[MB_LEN_MAX];
   char thousands[MB_LEN_MAX];
 #endif
@@ -44,6 +44,10 @@ _i18n_number_rewrite (CHAR_T *w, CHAR_T *rear_ptr)
   wctrans_t map = __wctrans ("to_outpunct");
   if (map != NULL)
     {
+      wdecimal = __towctrans (L'.', map);
+      wthousands = __towctrans (L',', map);
+
+#ifndef COMPILE_WPRINTF
       mbstate_t state;
       memset (&state, '\0', sizeof (state));
 
@@ -54,6 +58,7 @@ _i18n_number_rewrite (CHAR_T *w, CHAR_T *rear_ptr)
 
       if (__wcrtomb (thousands, wthousands, &state) == (size_t) -1)
        memcpy (thousands, ",", 2);
+#endif
     }
 
   /* Copy existing string so that nothing gets overwritten.  */