diff --git a/NEWS b/NEWS index 7b0e0b5..f87a363 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,57 @@ News for the tz database +Unreleased, experimental changes + + Changes affecting future time stamps + + Uruguay will stop observing DST. (Thanks to Steffen Thorsen + and Pablo Camargo.) + + Changes affecting past and future time stamps + + Moldova starts and ends DST at 00:00 UTC, not at 01:00 UTC. + (Thanks to Roman Tudos.) + + Changes affecting data format and code + + zic's '-y YEARISTYPE' option is no longer documented. The TYPE + field of a Rule line should now be '-'; the old values 'even', + 'odd', 'uspres', 'nonpres', 'nonuspres' were already undocumented. + Although the implementation has not changed, these features do not + work in the default installation, they are not used in the data, + and they are now considered obsolescent. + + zic now checks that two rules don't take effect at the same time. + (Thanks to Jon Skeet and Arthur David Olson.) Constraints on + simultaneity are now documented. + + The two characters '%z' in a zone format now stand for the UTC + offset, e.g., '-07' for seven hours behind UTC and '+0530' for + five hours and thirty minutes ahead. This better supports time + zone abbreviations conforming to POSIX.1-2001 and later. + + Changes affecting installed data files + + Comments for America/Halifax and America/Glace_Bay have been improved. + (Thanks to Brian Inglis.) + + Data entries have been simplified for Atlantic/Canary, Europe/Simferopol, + Europe/Sofia, and Europe/Tallinn. This yields slightly smaller + installed data files for Europe/Simferopol and Europe/Tallinn. + It does not affect timestamps. (Thanks to Howard Hinnant.) + + Changes affecting code + + zdump and zic no longer warn about valid time zone abbreviations + like '-05'. + + Some Visual Studio 2013 warnings have been suppressed. + (Thanks to Kees Dekker.) + + Changes affecting documentation + + tz-link.htm mentions Time Zone Database Parser (thanks to Howard Hinnant). + Release 2015e - 2015-06-13 10:56:02 -0700 diff --git a/difftime.c b/difftime.c index 449cdf0..5ee8eec 100644 --- a/difftime.c +++ b/difftime.c @@ -8,7 +8,7 @@ #include "private.h" /* for time_t and TYPE_SIGNED */ double ATTRIBUTE_CONST -difftime(const time_t time1, const time_t time0) +difftime(time_t time1, time_t time0) { /* ** If (sizeof (double) > sizeof (time_t)) simply convert and subtract diff --git a/europe b/europe index c64c41b..6449483 100644 --- a/europe +++ b/europe @@ -845,7 +845,7 @@ Zone Europe/Sofia 1:33:16 - LMT 1880 1:00 C-Eur CE%sT 1945 1:00 - CET 1945 Apr 2 3:00 2:00 - EET 1979 Mar 31 23:00 - 2:00 Bulg EE%sT 1982 Sep 26 2:00 + 2:00 Bulg EE%sT 1982 Sep 26 3:00 2:00 C-Eur EE%sT 1991 2:00 E-Eur EE%sT 1997 2:00 EU EE%sT @@ -1084,7 +1084,7 @@ Zone Europe/Tallinn 1:39:00 - LMT 1880 3:00 Russia MSK/MSD 1989 Mar 26 2:00s 2:00 1:00 EEST 1989 Sep 24 2:00s 2:00 C-Eur EE%sT 1998 Sep 22 - 2:00 EU EE%sT 1999 Nov 1 + 2:00 EU EE%sT 1999 Oct 31 4:00 2:00 - EET 2002 Feb 21 2:00 EU EE%sT @@ -1763,6 +1763,18 @@ Zone Europe/Malta 0:58:04 - LMT 1893 Nov 2 0:00s # Valletta # News from Moldova (in russian): # http://ru.publika.md/link_317061.html +# From Roman Tudos (2015-07-02): +# http://lex.justice.md/index.php?action=view&view=doc&lang=1&id=355077 +# From Paul Eggert (2015-07-01): +# The abovementioned official link to IGO1445-868/2014 states that +# 2014-10-26's fallback transition occurred at 03:00 local time. Also, +# http://www.trm.md/en/social/la-30-martie-vom-trece-la-ora-de-vara +# says the 2014-03-30 spring-forward transition was at 02:00 local time. +# Guess that since 1997 Moldova has switched one hour before the EU. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Moldova 1997 max - Mar lastSun 2:00 1:00 S +Rule Moldova 1997 max - Oct lastSun 3:00 0 - # Zone NAME GMTOFF RULES FORMAT [UNTIL] Zone Europe/Chisinau 1:55:20 - LMT 1880 @@ -1777,7 +1789,7 @@ Zone Europe/Chisinau 1:55:20 - LMT 1880 2:00 Russia EE%sT 1992 2:00 E-Eur EE%sT 1997 # See Romania commentary for the guessed 1997 transition to EU rules. - 2:00 EU EE%sT + 2:00 Moldova EE%sT # Monaco # Shanks & Pottenger give 0:09:20 for Paris Mean Time; go with Howse's @@ -2364,7 +2376,7 @@ Zone Europe/Simferopol 2:16:24 - LMT 1880 # changed in May. 2:00 E-Eur EE%sT 1994 May # From IATA SSIM (1994/1997), which also says that Kerch is still like Kiev. - 3:00 E-Eur MSK/MSD 1996 Mar 31 3:00s + 3:00 E-Eur MSK/MSD 1996 Mar 31 0:00s 3:00 1:00 MSD 1996 Oct 27 3:00s # IATA SSIM (1997-09) says Crimea switched to EET/EEST. # Assume it happened in March by not changing the clocks. @@ -2922,7 +2934,7 @@ Zone Africa/Ceuta -0:21:16 - LMT 1901 Zone Atlantic/Canary -1:01:36 - LMT 1922 Mar # Las Palmas de Gran C. -1:00 - CANT 1946 Sep 30 1:00 # Canaries T 0:00 - WET 1980 Apr 6 0:00s - 0:00 1:00 WEST 1980 Sep 28 0:00s + 0:00 1:00 WEST 1980 Sep 28 1:00u 0:00 EU WE%sT # IATA SSIM (1996-09) says the Canaries switch at 2:00u, not 1:00u. # Ignore this for now, as the Canaries are part of the EU. diff --git a/leap-seconds.list b/leap-seconds.list old mode 100755 new mode 100644 index 5bac01b..0a0bacb --- a/leap-seconds.list +++ b/leap-seconds.list @@ -199,10 +199,10 @@ # current -- the update time stamp, the data and the name of the file # will not change. # -# Updated through IERS Bulletin C49 -# File expires on: 28 December 2015 +# Updated through IERS Bulletin C50 +# File expires on: 28 June 2016 # -#@ 3660249600 +#@ 3676060800 # 2272060800 10 # 1 Jan 1972 2287785600 11 # 1 Jul 1972 @@ -246,4 +246,4 @@ # the hash line is also ignored in the # computation. # -#h 45e70fa7 a9df2033 f4a49ab0 ec648273 7b6c22c +#h 3d037453 3acade76 570bd8f8 be2b8bc9 55ec6fe8 diff --git a/localtime.c b/localtime.c index 423e13e..cc54ab0 100644 --- a/localtime.c +++ b/localtime.c @@ -1464,13 +1464,13 @@ localtime_tzset(time_t const *timep, struct tm *tmp, bool setname) } struct tm * -localtime(const time_t *const timep) +localtime(const time_t *timep) { return localtime_tzset(timep, &tm, true); } struct tm * -localtime_r(const time_t *const timep, struct tm *tmp) +localtime_r(const time_t *timep, struct tm *tmp) { return localtime_tzset(timep, tmp, false); } @@ -1499,7 +1499,7 @@ gmtsub(struct state const *sp, time_t const *timep, int_fast32_t offset, } struct tm * -gmtime(const time_t *const timep) +gmtime(const time_t *timep) { return gmtime_r(timep, &tm); } @@ -1509,7 +1509,7 @@ gmtime(const time_t *const timep) */ struct tm * -gmtime_r(const time_t *const timep, struct tm *tmp) +gmtime_r(const time_t *timep, struct tm *tmp) { gmtcheck(); return gmtsub(gmtptr, timep, 0, tmp); @@ -1518,7 +1518,7 @@ gmtime_r(const time_t *const timep, struct tm *tmp) #ifdef STD_INSPIRED struct tm * -offtime(const time_t *const timep, const long offset) +offtime(const time_t *timep, long offset) { gmtcheck(); return gmtsub(gmtptr, timep, offset, &tm); @@ -1671,7 +1671,7 @@ timesub(const time_t *const timep, const int_fast32_t offset, } char * -ctime(const time_t *const timep) +ctime(const time_t *timep) { /* ** Section 4.12.3.2 of X3.159-1989 requires that @@ -1684,7 +1684,7 @@ ctime(const time_t *const timep) } char * -ctime_r(const time_t *const timep, char *buf) +ctime_r(const time_t *timep, char *buf) { struct tm mytm; struct tm *tmp = localtime_r(timep, &mytm); @@ -2103,7 +2103,7 @@ mktime_z(struct state *sp, struct tm *tmp) #endif time_t -mktime(struct tm *const tmp) +mktime(struct tm *tmp) { time_t t; int err = lock(); @@ -2120,7 +2120,7 @@ mktime(struct tm *const tmp) #ifdef STD_INSPIRED time_t -timelocal(struct tm *const tmp) +timelocal(struct tm *tmp) { if (tmp != NULL) tmp->tm_isdst = -1; /* in case it wasn't initialized */ @@ -2128,13 +2128,13 @@ timelocal(struct tm *const tmp) } time_t -timegm(struct tm *const tmp) +timegm(struct tm *tmp) { return timeoff(tmp, 0); } time_t -timeoff(struct tm *const tmp, const long offset) +timeoff(struct tm *tmp, long offset) { if (tmp) tmp->tm_isdst = 0; diff --git a/northamerica b/northamerica index 88423e6..873a0f7 100644 --- a/northamerica +++ b/northamerica @@ -1235,10 +1235,19 @@ Zone America/Goose_Bay -4:01:40 - LMT 1884 # Happy Valley-Goose Bay # west Labrador, Nova Scotia, Prince Edward I -# From Paul Eggert (2006-03-22): +# From Brian Inglis (2015-07-20): +# From the historical weather station records available at: +# https://weatherspark.com/history/28351/1971/Sydney-Nova-Scotia-Canada +# Sydney shares the same time history as Glace Bay, so was +# likely to be the same across the island.... +# Sydney, as the capital and most populous location, or Cape Breton, would +# have been better names for the zone had we known this in 1996. + +# From Paul Eggert (2015-07-20): # Shanks & Pottenger write that since 1970 most of this region has been like # Halifax. Many locales did not observe peacetime DST until 1972; -# Glace Bay, NS is the largest that we know of. +# the Cape Breton area, represented by Glace Bay, is the largest we know of +# (Glace Bay was perhaps not the best name choice but no point changing now). # Shanks & Pottenger also write that Liverpool, NS was the only town # in Canada to observe DST in 1971 but not 1970; for now we'll assume # this is a typo. diff --git a/southamerica b/southamerica index 6bbc2c8..dcc063f 100644 --- a/southamerica +++ b/southamerica @@ -1713,8 +1713,19 @@ Rule Uruguay 2005 only - Oct 9 2:00 1:00 S Rule Uruguay 2006 only - Mar 12 2:00 0 - # From Jesper Nørgaard Welen (2006-09-06): # http://www.presidencia.gub.uy/_web/decretos/2006/09/CM%20210_08%2006%202006_00001.PDF -Rule Uruguay 2006 max - Oct Sun>=1 2:00 1:00 S -Rule Uruguay 2007 max - Mar Sun>=8 2:00 0 - +# +# From Steffen Thorsen (2015-06-30): +# ... it looks like they will not be using DST the coming summer: +# http://www.elobservador.com.uy/gobierno-resolvio-que-no-habra-cambio-horario-verano-n656787 +# http://www.republica.com.uy/este-ano-no-se-modificara-el-huso-horario-en-uruguay/523760/ +# From Paul Eggert (2015-06-30): +# Apparently restaurateurs complained that DST caused people to go to the beach +# instead of out to dinner. +# From Pablo Camargo (2015-07-13): +# http://archivo.presidencia.gub.uy/sci/decretos/2015/06/cons_min_201.pdf +# [dated 2015-06-29; repeals Decree 311/006 dated 2006-09-04] +Rule Uruguay 2006 2014 - Oct Sun>=1 2:00 1:00 S +Rule Uruguay 2007 2015 - Mar Sun>=8 2:00 0 - # Zone NAME GMTOFF RULES FORMAT [UNTIL] Zone America/Montevideo -3:44:44 - LMT 1898 Jun 28 -3:44:44 - MMT 1920 May 1 # Montevideo MT diff --git a/strftime.c b/strftime.c index 632f395..c01ce19 100644 --- a/strftime.c +++ b/strftime.c @@ -117,8 +117,7 @@ strftime_l(char *s, size_t maxsize, char const *format, struct tm const *t, #endif size_t -strftime(char * const s, const size_t maxsize, const char *const format, - const struct tm *const t) +strftime(char *s, size_t maxsize, const char *format, const struct tm *t) { char * p; int warn; @@ -149,8 +148,8 @@ strftime(char * const s, const size_t maxsize, const char *const format, } static char * -_fmt(const char *format, const struct tm *const t, char * pt, - const char *const ptlim, int *warnp) +_fmt(const char *format, const struct tm *t, char *pt, + const char *ptlim, int *warnp) { for ( ; *format; ++format) { if (*format == '%') { @@ -562,8 +561,7 @@ label: } static char * -_conv(const int n, const char *const format, char *const pt, - const char *const ptlim) +_conv(int n, const char *format, char *pt, const char *ptlim) { char buf[INT_STRLEN_MAXIMUM(int) + 1]; @@ -572,7 +570,7 @@ _conv(const int n, const char *const format, char *const pt, } static char * -_add(const char *str, char *pt, const char *const ptlim) +_add(const char *str, char *pt, const char *ptlim) { while (pt < ptlim && (*pt = *str++) != '\0') ++pt; diff --git a/tz-link.htm b/tz-link.htm index 242be84..85d71f2 100644 --- a/tz-link.htm +++ b/tz-link.htm @@ -8,7 +8,7 @@ - + Sources for Time Zone and Daylight Saving Time Data

The tz database

-The public-domain +The public-domain time zone database contains code and data that represent the history of local time for many representative locations around the globe. It is updated periodically to reflect changes made by political bodies -to time zone +to time zone boundaries and -daylight-saving +daylight-saving rules. This database (often called zoneinfo or tz) @@ -36,27 +36,27 @@ including the GNU C Library (used in -GNU/Linux), +GNU/Linux), Android, Firefox OS, FreeBSD, NetBSD, -OpenBSD, +OpenBSD, Cygwin, DJGPP, -MINIX, -MINIX, +webOS, AIX, -BlackBerry 10, +BlackBerry 10, iOS, Microsoft Windows, -OpenOpenVMS, Oracle Database, Oracle Solaris, and @@ -78,19 +78,19 @@ and other entries represent smaller regions like Starke County, Indiana, which switched from central to eastern time in 1991 and switched back in 2006. To use the database on an extended POSIX implementation set the TZ environment variable to the location's full name, e.g., TZ="America/New_York".

Associated with each region is a history of offsets from -Universal +Universal Time (UT), which is Greenwich Mean +href="https://en.wikipedia.org/wiki/Greenwich_Mean_Time">Greenwich Mean Time (GMT) with days beginning at midnight; for time stamps after 1960 this is more precisely Coordinated +href="https://en.wikipedia.org/wiki/Coordinated_Universal_Time">Coordinated Universal Time (UTC). The database also records when daylight saving time was in use, along with alphabetic time zone abbreviations such as EST @@ -113,7 +113,7 @@ code and latest data revisions are also available. The following shell commands download +href="https://en.wikipedia.org/wiki/Unix_shell">shell commands download these files to a GNU/Linux or similar host; see the downloaded README file for what to do next.

@@ -158,7 +158,7 @@ Here are some links that may be of interest.

Commentary on the tz database