diff options
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/charcnv.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source3/lib/charcnv.c b/source3/lib/charcnv.c index e8ceaf39b7..b9b9d90db6 100644 --- a/source3/lib/charcnv.c +++ b/source3/lib/charcnv.c @@ -84,6 +84,15 @@ static const char *charset_name(charset_t ch) } ret = ln; } +#ifdef HAVE_SETLOCALE + /* We set back the locale to C to get ASCII-compatible toupper/lower functions. + For now we do not need any other POSIX localisations anyway. When we should + really need localized string functions one day we need to write our own + ascii_tolower etc. + */ + setlocale(LC_ALL, "C"); + #endif + #endif if (!ret || !*ret) ret = "ASCII"; |