Commits
Marcus Calhoun-Lopez authored 62d431d198f
1 1 | diff -ur src/el.c /Users/macports/Fix/libedit-48/src/el.c |
2 2 | --- src/el.c 2012-12-13 13:01:25.000000000 -0700 |
3 3 | +++ src/el.c.orig 2013-02-07 11:05:15.000000000 -0700 |
4 4 | |
5 5 | * Initialize all the modules. Order is important!!! |
6 6 | */ |
7 - | el->el_flags = 0; |
7 + | el->el_flags = flags; |
8 8 | - if (setlocale(LC_CTYPE, NULL) != NULL){ |
9 9 | + char *loc = setlocale(LC_CTYPE, NULL); |
10 10 | + if (loc != NULL && strcmp(loc, "C") == 0) |
11 11 | + loc = setlocale(LC_CTYPE, ""); |
12 12 | + if (loc != NULL) { |
13 13 | if (strcmp(nl_langinfo(CODESET), "UTF-8") == 0) |
14 14 | el->el_flags |= CHARSET_IS_UTF8; |
15 15 | } |