Mantis - Resin
Viewing Issue Advanced Details
3512 minor always 05-13-09 12:32 08-26-09 11:55
damaan  
ferg  
normal  
closed 4.0.0  
fixed  
none    
none 4.0.2  
0003512: AbstractHttpRequest.getDateHeader() sometimes returns dates that are off by 24 hours
Some (older) dates don't seem to be properly handled when translating headers using HttpServletRequest.getDateHeader(). Sometimes the resulting value is off by 24 hours.

The code i AbstractHttpRequest delegates to a QDate instance that handles the parsing of the date header. Included in this bug report is a small test case that compares the result from parsing a date using a SimpleDateFormatter with the result from QDate.

When the tested date reaches the previous year, the test fails with the message:
"First failing timestamp: Wed, 31 Dec 2008 19:24:34 GMT (off by 86400000 ms) expected:<1230751474000> but was:<1230665074000>"
I originally came across the issue using Resin 3.0.23, but it seems to be the same in 4.0.0. The test case has been run against both versions with the same result.
 TestQDate.java [^] (1,061 bytes) 05-13-09 12:32

Notes
(0004169)
ferg   
08-26-09 11:55   
server/1m10