[time-nuts] Leap Quirks

Poul-Henning Kamp phk at phk.freebsd.dk
Sun Jan 4 00:11:12 UTC 2009


In message <495FF91C.60401 at rubidium.dyndns.org>, Magnus Danielson writes:

>We have at least three POSIX interpretations here.
>
>One which has UTC rubber seconds from 1970 to 1972 and from then true SI 
>seconds from 1972.
>One which has true SI seconds from 1970.
>One which has UTC tracking in pieces and is slid "sideways" to make 
>midnight match UTC midnight.
>
>The two first ones is interpretations of POSIX over UTC variations. The 
>third one is a hack of POSIX to make it kind of work anyway with NTP. 
>Only with the third interpretation POSIX midnight and UTC midnight is 
>the same.
>
>Now, which of them is "right"?

Strictly speaking none of them.

Instead of thinking of POSIX "wall-clock" facilities as a timekeeping
mechanism, think of them as asking the next stranger you meet what
time it is.

POSIX only offers you the ability to get an estimate of "wall-clock"
time, it does not guarantee that the such estimates will not represent
time going backwards, or that the amount of time between the two
requests will correspond to the difference between them.

The trouble is, obviously, that people pressume these properties.

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.



More information about the time-nuts mailing list