diff options
author | Yuri Chebotarev <ychebotarev@productengine.com> | 2010-06-23 17:47:24 +0300 |
---|---|---|
committer | Yuri Chebotarev <ychebotarev@productengine.com> | 2010-06-23 17:47:24 +0300 |
commit | 02f042d0dee2a3f413784b46317ce022cf2132f7 (patch) | |
tree | e9ef0b9255609c70bc0a0ac1b9e40ae8f5426e81 /indra/llcommon/llstring.cpp | |
parent | 4a0950e2d75a32d5eb4452520bff35967dc67ab2 (diff) | |
parent | d5fb82283997f50d81af7dbf364783a5961b75d5 (diff) |
merge
--HG--
branch : product-engine
Diffstat (limited to 'indra/llcommon/llstring.cpp')
-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) |