Re: Possible bug in Tomcat Date header handling

2011-08-26 Thread Mick Sear
I agree that a poorly configured system clock is not something Tomcat is responsible for, per se. However, there is a problem in the following code as I see it, which can be easily fixed by checking also for a negative number. This is a small fix that caters for people being dumb: /** * Get the

Possible bug in Tomcat Date header handling

2011-08-26 Thread Mick Sear
< 0) { synchronized (format) { if ((now - currentDateGenerated) > 1000) { currentDate = format.format(new Date(now)); currentDateGenerated = now; } } } return currentDate; ... Please let me know if there is a workaround o