Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 16 Aug 2006 09:30:17 GMT
From:      jau@iki.fi (Jukka A. Ukkonen)
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: bin/102121: strftime(3) fails on certain dates
Message-ID:  <200608160930.k7G9UH88041342@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/102121; it has been noted by GNATS.

From: jau@iki.fi (Jukka A. Ukkonen)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/102121: strftime(3) fails on certain dates
Date: Wed, 16 Aug 2006 12:26:45 +0300 (EEST)

 	Oops!
 
 	I was a bit too hasty (and definitely too tired) to write
 	the PR last night.
 
 	The true culprit is strptime() that already parses the date
 	"Tue, 15 Aug 2006 23:48:36 +0300 (EEST)" wrong producing
 	1597464000 on return, though the correct value should be
 	1155674916. (The offset here amounts to roughly 14 years.
 	I.e. 2020 instead of 2006.)
 
 	So, blame it on strptime(3) instead.
 
 
 	Cheers,
 		// jau
 .---  ..-  -.-  -.-  .-    .-  .-.-.-    ..-  -.-  -.-  ---  -.  .  -.
   /    Jukka A. Ukkonen,                             Oxit Ltd, Finland
  /__   M.Sc. (sw-eng & cs)                    (Phone) +358-500-606-671
    /   Internet: Jukka.Ukkonen(a)Oxit.Fi        (Home) +358-9-6215-280
   /    Internet: jau(a)iki.fi
  v
         .---  .-  ..-  ...-.-  ..  -.-  ..  .-.-.-  ..-.  ..
 + + + + My opinions are mine and mine alone, not my employers. + + + +



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200608160930.k7G9UH88041342>