Bug 106720
Summary: | new Date() after Feb 28 2034 returns an incorrect date | ||
---|---|---|---|
Product: | WebKit | Reporter: | Benjamin Juang <ben.juang+webkit> |
Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED DUPLICATE | ||
Severity: | Minor | CC: | lquinn |
Priority: | P4 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | Mac | ||
OS: | OS X 10.7 |
Benjamin Juang
Steps to Reproduce:
In javascript or using the Web Inspector Console:
1. Try creating a new Date() object with a date string that is at or after March 1, 2034.
Actual Results:
Date object will be off by one day.
Expecte Result:
Date object that matches the day you put in.
Console example:
> new Date("Feb 28 2034") // This is correct.
Tue Feb 28 2034 00:00:00 GMT-0800 (PST)
> new Date("Feb 29 2034") // This is correct.
Wed Mar 01 2034 00:00:00 GMT-0800 (PST)
> new Date("Mar 1 2034") // This is wrong. And any dates after March 1, 2034 will be off by a full day.
Tue Feb 28 2034 00:00:00 GMT-0800 (PST)
> new Date("Jan 01 2035")
Sun Dec 31 2034 00:00:00 GMT-0800 (PST)
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Liam Quinn
*** This bug has been marked as a duplicate of bug 130123 ***