diff options
author | Leyla Farazha <leyla@lindenlab.com> | 2010-06-22 16:53:49 -0700 |
---|---|---|
committer | Leyla Farazha <leyla@lindenlab.com> | 2010-06-22 16:53:49 -0700 |
commit | 204603e201ae4f3e088c5e14eefc536c4f567398 (patch) | |
tree | 7d14cbb5b385532302d8e792e0167e71f8c7a55a /indra/llcommon | |
parent | 25de07a379aaacfc7eb37dd91f33005acd3791ae (diff) | |
parent | 6296390cdee1102eb7b0ea5e1625a1d4c268b490 (diff) |
Merge
Diffstat (limited to 'indra/llcommon')
-rw-r--r-- | indra/llcommon/llstring.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/indra/llcommon/llstring.cpp b/indra/llcommon/llstring.cpp index f14d947734..1561bda201 100644 --- a/indra/llcommon/llstring.cpp +++ b/indra/llcommon/llstring.cpp @@ -994,7 +994,14 @@ void LLStringUtil::formatNumber(std::string& numStr, std::string decimals) convertToS32 (decimals, intDecimals); if (!sLocale.empty()) { - strStream.imbue (std::locale(sLocale.c_str())); + // std::locale() throws if the locale is unknown! (EXT-7926) + try + { + strStream.imbue(std::locale(sLocale.c_str())); + } catch (const std::exception &) + { + LL_WARNS_ONCE("Locale") << "Cannot set locale to " << sLocale << LL_ENDL; + } } if (!intDecimals) |