aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-11-11 06:50:35 +0000
committerhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-11-11 06:50:35 +0000
commitad8b8400de836f1ffb7cd9607295e202fd4b9f6c (patch)
treeef122fa7038cb1cf17bec6683c382517e1c9e340
parent8c5a217a35c01e16172c2ef33f28432323280616 (diff)
win32: disable digit locale variable such as 'LANG=1041'.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@737 ee746299-78ed-0310-b773-934348b2243d
-rw-r--r--ChangeLog5
-rw-r--r--ChangeLog.ja5
-rw-r--r--src/main.c17
3 files changed, 27 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index f42d504d..683ddf2c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2005-11-11
+ * src/main.c: app_init(): win32: disable digit locale variable such as
+ "LANG=1041".
+
+2005-11-11
+
* src/mainwindow.c: removed the outer border.
2005-11-10
diff --git a/ChangeLog.ja b/ChangeLog.ja
index 78398f7e..8b9a7780 100644
--- a/ChangeLog.ja
+++ b/ChangeLog.ja
@@ -1,5 +1,10 @@
2005-11-11
+ * src/main.c: app_init(): win32: "LANG=1041" のよな数値のロケール
+ 変数を無効にした。
+
+2005-11-11
+
* src/mainwindow.c: 外側の境界を除去。
2005-11-10
diff --git a/src/main.c b/src/main.c
index cb8d885c..e815c91f 100644
--- a/src/main.c
+++ b/src/main.c
@@ -402,6 +402,23 @@ static void app_init(void)
{
#ifdef G_OS_WIN32
gchar *newpath;
+ const gchar *lang_env;
+
+ /* disable locale variable such as "LANG=1041" */
+
+#define DISABLE_DIGIT_LOCALE(envstr) \
+{ \
+ lang_env = g_getenv(envstr); \
+ if (lang_env && g_ascii_isdigit(lang_env[0])) \
+ g_unsetenv(envstr); \
+}
+
+ DISABLE_DIGIT_LOCALE("LC_ALL");
+ DISABLE_DIGIT_LOCALE("LANG");
+ DISABLE_DIGIT_LOCALE("LC_CTYPE");
+ DISABLE_DIGIT_LOCALE("LC_MESSAGES");
+
+#undef DISABLE_DIGIT_LOCALE
#endif
setlocale(LC_ALL, "");