diff options
author | James Cook <james@lindenlab.com> | 2010-05-27 14:56:29 -0700 |
---|---|---|
committer | James Cook <james@lindenlab.com> | 2010-05-27 14:56:29 -0700 |
commit | c7a6a2e08f34b2cd21816a905c21e8017646001c (patch) | |
tree | 296ca43bd0267418649f0de8d2ee100e360736b0 /indra/llcommon/llstring.cpp | |
parent | 5250ac075a2bf2ce6712acdb908432229b110c1a (diff) |
DEV-50013 Friendlier info if you can't change name due to time lockout
Reviewed with Leyla
Diffstat (limited to 'indra/llcommon/llstring.cpp')
-rw-r--r-- | indra/llcommon/llstring.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/indra/llcommon/llstring.cpp b/indra/llcommon/llstring.cpp index b5a73ec1d1..637064d75f 100644 --- a/indra/llcommon/llstring.cpp +++ b/indra/llcommon/llstring.cpp @@ -694,14 +694,17 @@ void LLStringOps::setupDatetimeInfo (bool daylight) nowT = time (NULL); - tmpT = localtime (&nowT); - localT = mktime (tmpT); - tmpT = gmtime (&nowT); gmtT = mktime (tmpT); + tmpT = localtime (&nowT); + localT = mktime (tmpT); + sLocalTimeOffset = (long) (gmtT - localT); - + if (tmpT->tm_isdst) + { + sLocalTimeOffset -= 60 * 60; // 1 hour + } sPacificDaylightTime = daylight; sPacificTimeOffset = (sPacificDaylightTime? 7 : 8 ) * 60 * 60; |