about summary refs log tree commit diff
path: root/timezone/tzfile.h
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2006-11-11 02:05:42 +0000
committerUlrich Drepper <drepper@redhat.com>2006-11-11 02:05:42 +0000
commit064737fb74ac2a47916b9be162a6a098cde99816 (patch)
treeb1b2838f61216fc8378445bfc8fa291d32ae7b0f /timezone/tzfile.h
parent6decd24cc22116dea9da17c548d0ea0e9b6d5bfc (diff)
downloadglibc-064737fb74ac2a47916b9be162a6a098cde99816.tar.gz
glibc-064737fb74ac2a47916b9be162a6a098cde99816.tar.xz
glibc-064737fb74ac2a47916b9be162a6a098cde99816.zip
* time/tzfile.c (__tzfile_read): Extend to handle new file format
	on machines with 64-bit time_t.

	* timezone/checktab.awk: Update from tzcode2006o.
	* timezone/ialloc.c: Likewise.
	* timezone/private.h: Likewise.
	* timezone/scheck.: Likewise.
	* timezone/tzfile.h: Likewise.
	* timezone/tzselect.ksh: Likewise.
	* timezone/zdump.c: Likewise.
	* timezone/zic.c: Likewise.
Diffstat (limited to 'timezone/tzfile.h')
-rw-r--r--timezone/tzfile.h23
1 files changed, 14 insertions, 9 deletions
diff --git a/timezone/tzfile.h b/timezone/tzfile.h
index fb6ca9880f..3a9eee305a 100644
--- a/timezone/tzfile.h
+++ b/timezone/tzfile.h
@@ -21,7 +21,7 @@
 
 #ifndef lint
 #ifndef NOID
-static char	tzfilehid[] = "@(#)tzfile.h	7.18";
+static char	tzfilehid[] = "@(#)tzfile.h	8.1";
 #endif /* !defined NOID */
 #endif /* !defined lint */
 
@@ -49,7 +49,8 @@ static char	tzfilehid[] = "@(#)tzfile.h	7.18";
 
 struct tzhead {
 	char	tzh_magic[4];		/* TZ_MAGIC */
-	char	tzh_reserved[16];	/* reserved for future use */
+	char	tzh_version[1];		/* '\0' or '2' as of 2005 */
+	char	tzh_reserved[15];	/* reserved--must be zero */
 	char	tzh_ttisgmtcnt[4];	/* coded number of trans. time flags */
 	char	tzh_ttisstdcnt[4];	/* coded number of trans. time flags */
 	char	tzh_leapcnt[4];		/* coded number of leap seconds */
@@ -84,18 +85,22 @@ struct tzhead {
 */
 
 /*
+** If tzh_version is '2' or greater, the above is followed by a second instance
+** of tzhead and a second instance of the data in which each coded transition
+** time uses 8 rather than 4 chars,
+** then a POSIX-TZ-environment-variable-style string for use in handling
+** instants after the last transition time stored in the file
+** (with nothing between the newlines if there is no POSIX representation for
+** such instants).
+*/
+
+/*
 ** In the current implementation, "tzset()" refuses to deal with files that
 ** exceed any of the limits below.
 */
 
 #ifndef TZ_MAX_TIMES
-/*
-** The TZ_MAX_TIMES value below is enough to handle a bit more than a
-** year's worth of solar time (corrected daily to the nearest second) or
-** 138 years of Pacific Presidential Election time
-** (where there are three time zone transitions every fourth year).
-*/
-#define TZ_MAX_TIMES	370
+#define TZ_MAX_TIMES	1200
 #endif /* !defined TZ_MAX_TIMES */
 
 #ifndef TZ_MAX_TYPES