Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!stanford.edu!agate!ucbvax!AIVAX.RADC.AF.MIL!marks From: marks@AIVAX.RADC.AF.MIL (David Marks) Newsgroups: comp.sys.sgi Subject: Re: mcvert needs timeb.h? Message-ID: <9103081505.AA10605@AIVAX.RADC.AF.MIL> Date: 8 Mar 91 15:05:44 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 28 The structures in timeb.h are only referenced by the time2mac routine, so the problem is small. The ftime operation according to the BSD man page says: NAME time, ftime - get date and time ... DESCRIPTION These interfaces are obsoleted by gettimeofday(2). Time returns the time since 00:00:00 GMT, Jan. 1, 1970, measured in seconds. So, the answer is to use and gettimeofday instead of and ftime. The following is a first cut at what should work: ulong time2mac(time) ulong time; {struct timeval tptime; struct timezone tpzone; gettimeofday(&tptime, &tpzone); return long2mac(time + MACTIMEDIFF - 60 * (tpzone.tz_minuteswest - 60 * tpzone.tz_dsttime)); } Good Luck! Dave Marks Rome Laboratory marks@aivax.radc.af.mil