From owner-freebsd-bugs Sun Apr 26 07:30:11 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id HAA04372 for freebsd-bugs-outgoing; Sun, 26 Apr 1998 07:28:02 -0700 (PDT) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: from ifi.uio.no (0@ifi.uio.no [129.240.64.2]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id HAA04289 for ; Sun, 26 Apr 1998 07:26:45 -0700 (PDT) (envelope-from dag-erli@ifi.uio.no) Received: from gnipahellir.ifi.uio.no (2602@gnipahellir.ifi.uio.no [129.240.64.86]) by ifi.uio.no (8.8.8/8.8.7/ifi0.2) with ESMTP id QAA10354; Sun, 26 Apr 1998 16:26:43 +0200 (MET DST) Received: (from dag-erli@localhost) by gnipahellir.ifi.uio.no ; Sun, 26 Apr 1998 16:26:43 +0200 (MET DST) Mime-Version: 1.0 To: Karl Pielorz Cc: freebsd-bugs@FreeBSD.ORG Subject: Re: Year 2000 Compliance - localtime? References: <354315FC.7532C42D@tdx.co.uk> Organization: Gutteklubben Terrasse / KRST / PUMS / YASMW X-url: http://www.stud.ifi.uio.no/~dag-erli/ X-Stop-Spam: http://www.cauce.org From: dag-erli@ifi.uio.no (Dag-Erling Coidan =?iso-8859-1?Q?Sm=F8rgrav?= ) Date: 26 Apr 1998 16:26:42 +0200 In-Reply-To: Karl Pielorz's message of "Sun, 26 Apr 1998 12:09:48 +0100" Message-ID: Lines: 17 X-Mailer: Gnus v5.5/Emacs 19.34 Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Karl Pielorz writes: > Looking at the 'localtime' function - it returns a 'tm' structure, > including: > > int tm_year; /* year - 1900 */ > > Printing the contents of the 'tm_year' only gives the last two digits of the > year, i.e. it returns '98' at the moment... > > Is this right? - or are there some better functions or something I should be > using? Yes, this is right. If you check with your pocket calculator, I think you'll find 1900 was 98 years ago. tm_year will be 100 in year 2000. -- Noone else has a .sig like this one. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message