Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
locale.c: Don't change locale if already there
Changing the locale is cheap for some categories, but expensive for others. Changing LC_COLLATE is most expensive, requiring recalculation of the collation transformation mapping. This commit checks that we aren't already in the desired locale before changing locales. and does nothing if no change is needed.
- Loading branch information
1 parent
22a3c99
commit 23776c0
Showing
1 changed file
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters