aboutsummaryrefslogtreecommitdiff
path: root/libsylph/codeconv.c
diff options
context:
space:
mode:
Diffstat (limited to 'libsylph/codeconv.c')
-rw-r--r--libsylph/codeconv.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libsylph/codeconv.c b/libsylph/codeconv.c
index 08f60e22..36dd264c 100644
--- a/libsylph/codeconv.c
+++ b/libsylph/codeconv.c
@@ -2061,8 +2061,10 @@ const gchar *conv_get_current_locale(void)
cur_locale = g_getenv("LC_CTYPE");
if (!cur_locale || *cur_locale == '\0')
cur_locale = g_getenv("LANG");
+#ifdef HAVE_LOCALE_H
if (!cur_locale || *cur_locale == '\0')
cur_locale = setlocale(LC_CTYPE, NULL);
+#endif /* HAVE_LOCALE_H */
#endif /* G_OS_WIN32 */
debug_print("current locale: %s\n",