mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-11 02:51:15 -03:00
simplify, and fix, setting the current locale
Fix test setup bogosities. Specifically, they weren't hermetic with respect to locale env vars. Rewrite the handling of locale vars to simplify the code and make it more like the pattern most programs employ. Fixes #3110
This commit is contained in:
@@ -418,11 +418,12 @@ int main(int argc, char **argv) {
|
||||
assert(ANY_SENTINAL >= WILDCARD_RESERVED_BASE && ANY_SENTINAL <= WILDCARD_RESERVED_END);
|
||||
assert(R_SENTINAL >= INPUT_COMMON_BASE && R_SENTINAL <= INPUT_COMMON_END);
|
||||
|
||||
program_name = L"fish";
|
||||
set_main_thread();
|
||||
setup_fork_guards();
|
||||
|
||||
wsetlocale(LC_ALL, L"");
|
||||
program_name = L"fish";
|
||||
setlocale(LC_ALL, "");
|
||||
fish_setlocale();
|
||||
|
||||
// struct stat tmp;
|
||||
// stat("----------FISH_HIT_MAIN----------", &tmp);
|
||||
|
||||
Reference in New Issue
Block a user