*BSD News Article 9476


Return to BSD News archive

Received: by minnie.vk1xwt.ampr.org with NNTP
	id AA5825 ; Fri, 01 Jan 93 01:57:05 EST
Newsgroups: comp.unix.bsd
Path: sserve!manuel.anu.edu.au!munnari.oz.au!metro!ipso!runxtsa!bde
From: bde@runx.oz.au (Bruce Evans)
Subject: [386BSD] Happy old year!
Message-ID: <1993Jan1.120702.8189@runx.oz.au>
Organization: RUNX Un*x Timeshare.  Sydney, Australia.
Date: Fri, 1 Jan 93 12:07:02 GMT
Lines: 31

The new year started fairly early in Australia.  But 386BSD-0.1 had two
Dec 31, 1992's.  I cut the second one short after 22.5 hours using this
fix.

*** clock.c~	Wed Dec 25 09:23:24 1991
--- clock.c	Thu Dec 31 22:34:16 1992
***************
*** 87,92 ****
  	unsigned long ret;
  
! 	ret = 0; y = y - 70;
! 	for(i=0;i<y;i++) {
  		if (i % 4) ret += 365*24*60*60;
  		else ret += 366*24*60*60;
--- 88,93 ----
  	unsigned long ret;
  
! 	ret = 0;
! 	for(i = 70; i < y; i++) {
  		if (i % 4) ret += 365*24*60*60;
  		else ret += 366*24*60*60;
***************
*** 146,150 ****
  	sec += bcd(rtcin(RTC_MIN)) * 60;			/* minutes */
  	sec += bcd(rtcin(RTC_SEC));				/* seconds */
- 	sec -= 24*60*60; /* XXX why ??? */
  
  #ifdef notdef
--- 147,150 ----
-- 
Bruce Evans  (bde@runx.oz.au)