bin/102121: strftime(3) fails on certain dates

Daniel Hartmeier daniel at benzedrine.cx
Wed Aug 16 13:20:15 UTC 2006


The following reply was made to PR bin/102121; it has been noted by GNATS.

From: Daniel Hartmeier <daniel at benzedrine.cx>
To: "Jukka A. Ukkonen" <jau at iki.fi>
Cc: FreeBSD-gnats-submit at freebsd.org
Subject: Re: bin/102121: strftime(3) fails on certain dates
Date: Wed, 16 Aug 2006 15:12:30 +0200

 On Wed, Aug 16, 2006 at 01:03:37AM +0300, Jukka A. Ukkonen wrote:
 
 > 	Try for e.g.
 > 
 > 	/bin/date -r 1597464920
 
 $ date; date +%s
 Wed Aug 16 15:07:07 MEST 2006
 1155733627
 
 $ echo "1597464920-1155733627" | bc
 441731293
 
 $ echo "441731293/60/60/24/365" | bc
 14
 
 That timestamp simply IS that far in the future (2020, not 2006)
 
 > 	The correct date should be ...
 > 
 > 	Tue Aug 15 23:48:40 EET DST 2006
 > 
 > 	or
 > 
 > 	Tue Aug 15 22:48:40 EET 2006
 > 
 > 	when DST is not used.
 
 Why?
 
 Daniel


More information about the freebsd-bugs mailing list