1
0
mirror of https://github.com/tmux/tmux.git synced 2025-04-05 15:48:53 +00:00

Try C.UTF-8 which is also a commonly useful locale on some platforms,

from Romain Francoise.
This commit is contained in:
nicm 2017-07-03 08:08:30 +00:00
parent fa677fc0e1
commit 42285ac989

3
tmux.c
View File

@ -196,7 +196,8 @@ main(int argc, char **argv)
int opt, flags, keys;
const struct options_table_entry *oe;
if (setlocale(LC_CTYPE, "en_US.UTF-8") == NULL) {
if (setlocale(LC_CTYPE, "en_US.UTF-8") == NULL &&
setlocale(LC_CTYPE, "C.UTF-8") == NULL) {
if (setlocale(LC_CTYPE, "") == NULL)
errx(1, "invalid LC_ALL, LC_CTYPE or LANG");
s = nl_langinfo(CODESET);