Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Zsh 2.6 and Y2K status



On Jul 2,  3:58pm, Chan Sean wrote:
} Subject: Zsh 2.6 and Y2K status
}
} On behalf of my client WMC Resources Ltd. I need to know if ZSH is Y2K
} compliant. May I know where I can find such information??

You can confirm the following by looking at the source code yourself if
necessary; there's no other definitive reference:

Zsh uses UNIX/POSIX time_t, timeval, and tm data types for internal date
manipulations.  These types either do not store year values at all (for
example, time_t is measured in seconds since midnight, Jan 1, 1970) or
store them as integer types and NOT as pairs of digits.  Thus there can
be no overflows at year 2000.  On some unix systems, time_t is a 32-bit
value and will overflow during the year 2038, but more modern systems use
a 64-bit time_t.

The only input and output of dates that zsh performs is optional history
time-stamping.  This is performed using time_t values converted to long
integers, which are either 32 or 64 bits, see above.

Note, however, that zsh does provide facilities for formatted date output,
so it's possible that scripts written for zsh might employ 2-digit years.
Shell scripts should always be considered separate programs and therefore
evaluated individually.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com



Messages sorted by: Reverse Date, Date, Thread, Author