From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/4370 Path: news.gmane.org!not-for-mail From: Szabolcs Nagy Newsgroups: gmane.linux.lib.musl.general Subject: Re: [PATCHv2] Add support for leap seconds in zoneinfo files Date: Thu, 5 Dec 2013 15:21:02 +0100 Message-ID: <20131205142102.GZ1685@port70.net> References: <5294EE35.8040603@skarnet.org> <20131126233212.GE24286@brightrain.aerifal.cx> <529570BB.2060804@skarnet.org> <20131127042550.GI24286@brightrain.aerifal.cx> <529588D8.3020006@skarnet.org> <20131127184307.GN1685@port70.net> <52965735.9070409@skarnet.org> <529FD33A.8000509@skarnet.org> <20131205051809.GY1685@port70.net> <52A0404A.4050106@skarnet.org> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1386253271 3017 80.91.229.3 (5 Dec 2013 14:21:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 5 Dec 2013 14:21:11 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-4374-gllmg-musl=m.gmane.org@lists.openwall.com Thu Dec 05 15:21:16 2013 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1VoZnn-0008EP-Di for gllmg-musl@plane.gmane.org; Thu, 05 Dec 2013 15:21:15 +0100 Original-Received: (qmail 25758 invoked by uid 550); 5 Dec 2013 14:21:14 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 25748 invoked from network); 5 Dec 2013 14:21:13 -0000 Content-Disposition: inline In-Reply-To: <52A0404A.4050106@skarnet.org> User-Agent: Mutt/1.5.21 (2010-09-15) Xref: news.gmane.org gmane.linux.lib.musl.general:4370 Archived-At: * Laurent Bercot [2013-12-05 08:58:50 +0000]: > This is true if and only if all leap seconds are 1, which is the case for now > and in the foreseeable future, but my version supports even the improbable > case where different corrections are introduced. "The current rules for leap seconds in UTC are specified by ITU-R TF.460. They state that a leap second may be added (or subtracted) at the end of any month, but that first preference is given to June and December, and second preference is given to March and September." this breaks down after <2000 years when there will be 12 leapseconds/year, allowing 1 leapsecond/day will work for >40000 years the UTC definition does not allow double leap seconds so posix and iso c specify the [0,60] range for tm_sec (ie >1 leap seconds cannot be supported, <-1 leap seconds could be supported, but since the earth slows down that wont happen) systems will not break because a big leap is introduced 10k years from now, but because there is a day with 86401 seconds about every 2 years