Date: Wed, 7 Oct 1998 13:53:34 +1000 (EST) From: Q <q@fan.net.au> To: =?ISO-8859-1?Q?Dag-Erling_C=2E_Sm=F8rgrav?= <dag-erli@ifi.uio.no> Cc: freebsd-bugs@FreeBSD.ORG Subject: Re: misc/8156: mktime does not set tm_wday Message-ID: <Pine.BSF.4.02.9810071337330.215-100000@gromit.fan.net.au> In-Reply-To: <xzpzpb9hhgu.fsf@skejdbrimir.ifi.uio.no>
next in thread | previous in thread | raw e-mail | index | archive | help
On 6 Oct 1998, Dag-Erling C. Smørgrav wrote:
> Q <q@fan.net.au> writes:
> > It's not a bug. Your using the struct incorrectly. Every call you make to
> > mktime() will be returning -1. You are effectively asking it for the year
> > 3899. Which can't be expresses using a time_t value. Change 'tm_year =
> > 1999' to 'tm_year = 99'. You should put your Y2K hat on if you plan to use
> > a 'struct tm' in your application.
>
> If you think tm_year poses a Y2K problem, you've got another think
> coming. Apart from that, your analysis is correct. I'm closing the PR.
I wasn't implying a Y2K issue with using the struct, only that there can
be issues if not used correctly. I was only suggesting that one should
be careful and think when doing maths with dates.
Sorry I probably should have been a little more direct.
Seeya...Q
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
_____ / Quinton Dolan - q@fan.net.au
__ __/ / / __/ / / Systems Administrator
/ __ / _/ / / Fast Access Network
__/ __/ __/ ____/ / - / Gold Coast, QLD, Australia
_______ / Ph: +61 7 5574 1050
\_\ SAGE-AU Member
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.02.9810071337330.215-100000>
