>From: Doug McNutt <douglist at macnauchtan.com> >Does anyone have reliable information on just what is stored in the >system clock? >I'm pretty sure it was seconds since Jan 0 1904 as observed in the >selected local time zone in MacOS 1. But was it DST sensitive? Or >was the DST part arranged in the display only? As in all Unix, the time and all timestamps are TimeZone and DST free. It's added at display. Using perl to show what time zero is, gives 1st Jan 1970. >And just what is it now with 64 bits of time stored as seconds? Just before Mon Jul 16 18:08:55 BST 2007 (which is GMT + 1) I got $ perl -e 'print localtime(), "\n"' 3581816610711961 >And what is it in the underlying BSD kernel of Mac OS neXt? I think >it's seconds from Jan 0 1970 as measured in universal time >coordinated - UTC - but disregarding leap seconds. Leap seconds are not allowed for directly. They are accounted for in the human way - leap years. If they were we would get support calls for the time being 'wrong'. Unix clock time transformed by Time Zone and DST should give wallclock time (and date) >I would hope that time stamps placed on stored files were >independent of governments' vagaries regarding daylight time but are >they? If I read a file from an early OS machine on OS neXt do I have >to correct for system differences before I compare with a local copy? Yes to the first. They are independent under Unix. It would take a lot of work to port Unix to be otherwise. David >--> Evolution made it possible for mankind to invent religion. <-- Ah, evolution ... one of God's clever inventions ;-) -- David Ledger - Freelance Unix Sysadmin in the UK. Chair of HPUX SysAdmin SIG of hpUG technical user group (www.hpug.org.uk) david.ledger at ivdcs.co.uk www.ivdcs.co.uk