From owner-freebsd-bugs Wed Jul 10 18:40:04 1996 Return-Path: owner-bugs Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id SAA04672 for bugs-outgoing; Wed, 10 Jul 1996 18:40:04 -0700 (PDT) Received: (from gnats@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id SAA04654; Wed, 10 Jul 1996 18:40:02 -0700 (PDT) Date: Wed, 10 Jul 1996 18:40:02 -0700 (PDT) Message-Id: <199607110140.SAA04654@freefall.freebsd.org> To: freebsd-bugs Cc: From: Mike Pritchard Subject: Re: misc/1380: Year 2000 breakage with tm_year Reply-To: Mike Pritchard Sender: owner-bugs@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk The following reply was made to PR misc/1380; it has been noted by GNATS. From: Mike Pritchard To: sjr@zombie.ncsc.mil (Stephen J. Roznowski) Cc: FreeBSD-gnats-submit@freebsd.org Subject: Re: misc/1380: Year 2000 breakage with tm_year Date: Wed, 10 Jul 1996 18:35:45 -0700 (PDT) Stephen J. Roznowski wrote: > >Description: > > Several programs have a hardcoded 19 in responses for the year. > This will break in 4 years... > [...] > --- 1467,1474 ---- > struct tm *gmtime(); > t = gmtime(&stbuf.st_mtime); > reply(213, > ! "%04d%02d%02d%02d%02d%02d", > ! 1900+t->tm_year, t->tm_mon+1, t->tm_mday, Isn't there a TM_YEAR_BASE symbol defined somewhere that should be used instead of a hardcoded 1900? -- Mike Pritchard mpp@FreeBSD.org "Go that way. Really fast. If something gets in your way, turn"