Strange output from zdump for 2038

Dave Rolsky autarch at urth.org
Mon Jul 21 15:40:51 UTC 2003


On Mon, 21 Jul 2003, Olson, Arthur David (NIH/NCI) wrote:

> The zdump manual page notes the output to be expected when using the -v
> option:
>
>      -v   For each zonename on the command line, print  the  time
>           at  the  lowest  possible  time value, the time one day
>           after the lowest possible time value,  the  times  both
>           one  second  before  and  exactly at each detected time
>           discontinuity, the  time  at  one  day  less  than  the
>           highest  possible  time  value,  and  the  time  at the
>           highest  possible  time  value,  Each  line  ends  with
>           isdst=1  if  the  given time is Daylight Saving Time or
>           isdst=0 otherwise.
>
> So the two 1901 lines and the two 2038 lines are to be expected.

An explicit mention of the 32-bit int overflow problem might be in order,
I think.  Something along the lines of:

 Because most systems represent seconds since the epoch as a 32-bit int,
 discontinuities may be incorrectly detected when this int overflows.  For
 a signed 32-bit int, this will occur in the years 1901 and 2038.  The
 discontinuities reported because of this overflow do not represent
 actual changes in that time zone.


-dave

/*=======================
House Absolute Consulting
www.houseabsolute.com
=======================*/



More information about the tz mailing list