summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorAndrew Dyukov <adyukov@productengine.com>2010-09-16 20:01:00 +0300
committerAndrew Dyukov <adyukov@productengine.com>2010-09-16 20:01:00 +0300
commit0098a236076701bc5bbfa80e2f97f360d332b6a8 (patch)
tree1d7d142fd8d1ec374ae4ab5a4b6039882a8df8a7 /indra
parent1dbcc3fff79b55038178e493df0cc0c3a4d66221 (diff)
STORM-180 FIXED Fixed crash on login in Japanese locale.
The crash was caused by erroneous getting of month name from vector with week day names in LLStringUtil::formatDatetime(). This code woth introduced in June, so though it didn't work properly, it didn't cause the crash(cause June is 5th month). But when number of current month exceeded number of days in week(this happened in August cause it is 8th) code started getting 8th element from vector with 7. This caused the crash. It reproduced only on Japanese locale because only there code that caused it was used(see STORM-177 for details). This changeset seems to fix STORM-177 too. - Used vector with months names where it should be.
Diffstat (limited to 'indra')
-rw-r--r--indra/llcommon/llstring.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/indra/llcommon/llstring.cpp b/indra/llcommon/llstring.cpp
index 33b55d843c..ae7e624a1a 100644
--- a/indra/llcommon/llstring.cpp
+++ b/indra/llcommon/llstring.cpp
@@ -1112,7 +1112,7 @@ bool LLStringUtil::formatDatetime(std::string& replacement, std::string token,
else if(LLStringOps::sMonthList.size() == 12 && code == "%B")
{
struct tm * gmt = gmtime (&loc_seconds);
- replacement = LLStringOps::sWeekDayList[gmt->tm_mon];
+ replacement = LLStringOps::sMonthList[gmt->tm_mon];
}
else if( !LLStringOps::sDayFormat.empty() && code == "%d" )
{