Bug 138427
Summary: | Incorrect timezone information used for British Standard time for 1970 | ||
---|---|---|---|
Product: | WebKit | Reporter: | Boris Zbarsky <bzbarsky> |
Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
Status: | NEW | ||
Severity: | Normal | CC: | ggaren, mark.lam, msaboff |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
Boris Zbarsky
Consider this expression:
(new Date(0)).toLocaleString()
When run in the UK timezone, JavaScriptCore returns:
"January 1, 1970 at 1:00:00 AM GMT+1"
which is correct: at the time BST was GMT+1 due to he British Standard Time experiment; see http://en.wikipedia.org/wiki/British_Summer_Time#Periods_of_deviation
However this expression:
+(new Date(1970, 0, 1))
returns 0 in JavaScriptCore, whereas the correct value is -3600000, because the provided date/time is in local time, which was one hour ahead of GMT in 1970.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |