Skip to content

Commit

Permalink
Merge pull request #753 from lcheylus/utf8-ctype
Browse files Browse the repository at this point in the history
  • Loading branch information
aristocratos committed Feb 11, 2024
2 parents 97e78eb + 283ad3e commit 1d62896
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/btop.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -936,7 +936,7 @@ int main(int argc, char **argv) {
else {
string found;
bool set_failure{};
for (const auto loc_env : array{"LANG", "LC_ALL"}) {
for (const auto loc_env : array{"LANG", "LC_ALL", "LC_CTYPE"}) {
if (std::getenv(loc_env) != nullptr and str_to_upper(s_replace((string)std::getenv(loc_env), "-", "")).ends_with("UTF8")) {
found = std::getenv(loc_env);
if (std::setlocale(LC_ALL, found.c_str()) == nullptr) {
Expand Down

0 comments on commit 1d62896

Please sign in to comment.