Fixed charset handling of the filenames.
authorlace <>
Wed, 25 Jan 2006 17:36:45 +0000 (17:36 +0000)
committerlace <>
Wed, 25 Jan 2006 17:36:45 +0000 (17:36 +0000)
 - No longer redefine the 'LANG'/'LC_*' settings.
   - It was valid for udpgate handling only LC_MESSAGES and its windows.

src/libcaptive/client/standalone.c

index b859013..d6addc7 100644 (file)
@@ -43,6 +43,17 @@ void captive_standalone_init(void)
         * as prevented by: glib-2.6.4-noaliases.patch
         */
 
+       /* Do not redefine the 'LANG'/'LC_*' settings to avoid corrupting
+        * filenames charset interpretation.
+        * Do not redefine the 'LOCPATH' settings as we just hope to find
+        * the right definitions - we do not supply any ourselves.
+        * Be sure the locale messages dirs are not ".utf8" suffixed:
+        * glibc-20050524T1606/locale/findlocale.c:
+        *      If the locale name contains a charset name and the charset name used in
+        *      the locale (present in the LC_CTYPE data) is not the same (after
+        *      resolving aliases etc) we reject the locale
+        */
+#if 0
        if (getenv("LC_ALL"))
                setenv("LC_MESSAGES",getenv("LC_ALL"),
                                1);     /* overwrite */
@@ -60,6 +71,7 @@ void captive_standalone_init(void)
        /* It may differ across distributions. Maybe - just expected. */
        setenv("LOCPATH",LOCALEDIR,
                        1);     /* overwrite */
+#endif
 
 #endif /* ENABLE_STANDALONE */