[imp] wrong date/time in mailbox view

Jan Schneider jan@horde.org
Thu, 29 Nov 2001 17:28:49 +0100


Zitat von Ahmed <ashihab@alcahest.com>:

> Yes, I get the same problem. my timezone is defined as Europe/London.
> 
> Horde/IMP/Turba latest CVS (20.11.2001 20:00GMT)
> 
> Ahmed...
> 
> 
> Quoting Jan Schneider <jan@horde.org>:
> 
> > Is anyone else having this?
> > 
> > The date and time field in the mailbox view get totally messed up for
> all 
> > messages the have the same timezone like me set in their headers
> (+0100), 
> > e.g. my own mails and all the mails from the European fellows.
> > 
> > The mail server doesn't seem to have any problems because the messages
> get 
> > sorted in the correct order.
> > 
> > I'm not sure but looks like the date is always shown as four days
> earlier, 
> > e.g. mails from today are shown as from 11/17.

If anyone else is having this: It's a bug in PHP, reported to the PHP team 
and hopefully will be fixed before the 4.1 release.

This is the patch against 4.1.0RC3 if you have any problems:

--- ext/standard/parsedate.y.orig       Thu Nov 15 15:33:41 2001
+++ ext/standard/parsedate.y    Thu Nov 29 15:28:52 2001
@@ -255,7 +255,7 @@
            yySeconds = $5;
            yyMeridian = MER24;
            yyHaveZone++;
-               if ($6 < -100 || $6 > 100) {
+               if ($6 <= -100 || $6 >= 100) {
                        yyTimezone =  -$6 % 100 + (-$6 / 100) * 60;
                } else {
                        yyTimezone =  -$6 * 60;

Jan.

::::::::::::::::::::::::::::::::::::::::
AMMMa AG - discover your knowledge
:::::::::::::::::::::::::::
Detmolder Str. 25-33 :: D-33604 Bielefeld
fon +49.521.96878-0 :: fax  +49.521.96878-20
http://www.ammma.de
::::::::::::::::::::::::::::::::::::::::::::::