[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Bug in GNU date ??
From: |
MUTTON, PETER |
Subject: |
Bug in GNU date ?? |
Date: |
Mon, 05 Apr 2004 16:57:56 -0400 |
Hi,
I'm not sure if this a bug or correct behaviour.....
I'm using GNU date to convert timestamps between timezones and it
doesn't correctly handle Daylight Savings time. E.g.
#> /usr/local/bin/date
Mon Apr 5 16:42:28 EDT 2004
#> /usr/local/bin/date -u -d "Mon Apr 5 16:42:28 EDT 2004"
Mon Apr 5 20:42:28 UTC 2004
^^ correct as we are now Daylight Saving, 4 hrs
behind GMT
#> /usr/local/bin/date -u -d "Sat Apr 3 16:42:28 EDT 2004"
Sat Apr 3 20:42:28 UTC 2004
^^ should be 21 as we moved to Daylight Saving time
on Apr 4
#> zdump -v /usr/share/lib/zoneinfo/Canada/Eastern |grep 2004
/usr/share/lib/zoneinfo/Canada/Eastern Mon Apr 5 20:54:27 2004
UTC = Mon Apr 5 16:54:27 2004 EDT isdst=1
/usr/share/lib/zoneinfo/Canada/Eastern Sun Apr 4 06:59:59 2004
UTC = Sun Apr 4 01:59:59 2004 EST isdst=0
/usr/share/lib/zoneinfo/Canada/Eastern Sun Apr 4 07:00:00 2004
UTC = Sun Apr 4 03:00:00 2004 EDT isdst=1
/usr/share/lib/zoneinfo/Canada/Eastern Sun Oct 31 05:59:59 2004
UTC = Sun Oct 31 01:59:59 2004 EDT isdst=1
/usr/share/lib/zoneinfo/Canada/Eastern Sun Oct 31 06:00:00 2004
UTC = Sun Oct 31 01:00:00 2004 EST isdst=0
Peter Mutton
- Bug in GNU date ??,
MUTTON, PETER <=