diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/nsterm.m | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/nsterm.m b/src/nsterm.m index 4048ac46546..34c5395b630 100644 --- a/src/nsterm.m +++ b/src/nsterm.m | |||
| @@ -596,8 +596,15 @@ ns_init_locale (void) | |||
| 596 | 596 | ||
| 597 | @try | 597 | @try |
| 598 | { | 598 | { |
| 599 | /* It seems OS X should probably use UTF-8 everywhere. | ||
| 600 | 'localeIdentifier' does not specify the encoding, and I can't | ||
| 601 | find any way to get the OS to tell us which encoding to use, | ||
| 602 | so hard-code '.UTF-8'. */ | ||
| 603 | NSString *localeID = [NSString stringWithFormat:@"%@.UTF-8", | ||
| 604 | [locale localeIdentifier]]; | ||
| 605 | |||
| 599 | /* Set LANG to locale, but not if LANG is already set. */ | 606 | /* Set LANG to locale, but not if LANG is already set. */ |
| 600 | setenv("LANG", [[locale localeIdentifier] UTF8String], 0); | 607 | setenv("LANG", [localeID UTF8String], 0); |
| 601 | } | 608 | } |
| 602 | @catch (NSException *e) | 609 | @catch (NSException *e) |
| 603 | { | 610 | { |