[BusyBox] Date function (again)
Manuel Novoa III
mjn3 at codepoet.org
Wed Jul 23 23:27:11 UTC 2003
Hello,
On Wed, Jul 23, 2003 at 03:22:09PM -0700, Sid Wade wrote:
> One of my SQA people just pointed out an interesting feature to me. If
> I have /etc/TZ set to some zone indicating we have daylight time, in my
> case PST8PDT, and I change the date/time from now (July) to sometime
> after daylight time ends, say November, the result comes back an hour
> earlier than the time I entered, as if we had actually ticked our way
> across that time change. Conversely, setting it back to July gives me a
> time result one hour later than the string I put into the date command.
> Is this expected behavior or a bug?
It was a bug in the busybox date applet. The code was calling mktime()
without resetting the tm_isdst field to -1. So, mktime() was using
the current daylight savings time setting for the new date.
I just checked in a quick fix to cvs. Unfortunately, I don't have time
to address the severe bloat problem... :-(
Manuel
More information about the busybox
mailing list