aboutsummaryrefslogtreecommitdiffstats
path: root/src/main.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-12-25 04:17:41 +0100
committerMax Kellermann <max@duempel.org>2008-12-25 04:17:41 +0100
commit1f8e9dc0236a0810e68e6017a9400a1e7a70491d (patch)
treeda8b5fd40bd597b37d5e49200f00a89d084b9d96 /src/main.c
parentc39eb2cdf399c740c24884997364cf84c64fd46b (diff)
downloadmpd-1f8e9dc0236a0810e68e6017a9400a1e7a70491d.tar.gz
mpd-1f8e9dc0236a0810e68e6017a9400a1e7a70491d.tar.xz
mpd-1f8e9dc0236a0810e68e6017a9400a1e7a70491d.zip
initialize NLS without locale support
Initialize the NLS subsystem even when locale support is disabled. This may be a very exotic configuration, but it is valid.
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index a0f7c0c99..8a26001c3 100644
--- a/src/main.c
+++ b/src/main.c
@@ -383,12 +383,15 @@ main(int argc, const char *argv[])
charset = charset_init();
/* initialize i18n support */
+#endif
+
#ifdef ENABLE_NLS
setlocale(LC_MESSAGES, "");
bindtextdomain(GETTEXT_PACKAGE, LOCALE_DIR);
+#ifdef ENABLE_LOCALE
bind_textdomain_codeset(GETTEXT_PACKAGE, charset);
- textdomain(GETTEXT_PACKAGE);
#endif
+ textdomain(GETTEXT_PACKAGE);
#endif
/* initialize options */