pgsql: Sync our copy of the timezone library with IANA release tzcode20

Started by Tom Laneover 9 years ago3 messagescomitters
Jump to latest
#1Tom Lane
tgl@sss.pgh.pa.us

Sync our copy of the timezone library with IANA release tzcode2016g.

This is mostly to absorb some corner-case fixes in zic for year-2037
timestamps. The other changes that have been made are unlikely to affect
our usage, but nonetheless we may as well take 'em.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/f3094920a567cde6c86adf36a1a033d7431b11ff

Modified Files
--------------
src/timezone/localtime.c | 5 +-
src/timezone/private.h | 1 +
src/timezone/strftime.c | 2 +-
src/timezone/zic.c | 440 ++++++++++++++++++++++++++---------------------
4 files changed, 250 insertions(+), 198 deletions(-)

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers

#2Thomas Munro
thomas.munro@gmail.com
In reply to: Tom Lane (#1)
Re: pgsql: Sync our copy of the timezone library with IANA release tzcode20

On Thu, Oct 20, 2016 at 11:56 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:

Sync our copy of the timezone library with IANA release tzcode2016g.

This is mostly to absorb some corner-case fixes in zic for year-2037
timestamps. The other changes that have been made are unlikely to affect
our usage, but nonetheless we may as well take 'em.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/f3094920a567cde6c86adf36a1a033d7431b11ff

Modified Files
--------------
src/timezone/localtime.c | 5 +-
src/timezone/private.h | 1 +
src/timezone/strftime.c | 2 +-
src/timezone/zic.c | 440 ++++++++++++++++++++++++++---------------------
4 files changed, 250 insertions(+), 198 deletions(-)

My compiler (Apple LLVM version 8.0.0 (clang-800.0.38)) doesn't like this:

zic.c:427:53: error: implicit conversion from 'unsigned long long' to
'int' changes value from 18446744073709551615 to -1
[-Werror,-Wconstant-conversion]
int amax = nitems_max < SIZE_MAX ?
nitems_max : SIZE_MAX;
~~~~
^~~~~~~~
/usr/include/stdint.h:153:20: note: expanded from macro 'SIZE_MAX'
#define SIZE_MAX UINT64_MAX
^~~~~~~~~~
/usr/include/stdint.h:87:27: note: expanded from macro 'UINT64_MAX'
#define UINT64_MAX 18446744073709551615ULL
^~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

--
Thomas Munro
http://www.enterprisedb.com

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Thomas Munro (#2)
Re: pgsql: Sync our copy of the timezone library with IANA release tzcode20

Thomas Munro <thomas.munro@enterprisedb.com> writes:

On Thu, Oct 20, 2016 at 11:56 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:

Sync our copy of the timezone library with IANA release tzcode2016g.

My compiler (Apple LLVM version 8.0.0 (clang-800.0.38)) doesn't like this:
zic.c:427:53: error: implicit conversion from 'unsigned long long' to
'int' changes value from 18446744073709551615 to -1
[-Werror,-Wconstant-conversion]
int amax = nitems_max < SIZE_MAX ? nitems_max : SIZE_MAX;
~~~~ ^~~~~~~~

Hmm ... I wonder what the IANA guys think they're doing here?
There are no platforms on which INT_MAX is more than SIZE_MAX.
I think we can just take this out.

(My RHEL6 compiler didn't object to this, but I can reproduce
it on Mac.)

regards, tom lane

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers