Thread: Re: [pgsql-hackers-win32] [HACKERS] win32 crash in initdb

Re: [pgsql-hackers-win32] [HACKERS] win32 crash in initdb

From
"Magnus Hagander"
Date:
>> The crash people are getting in initdb is due to the 1.19 revision to
>> pgtz.c.  Not sure why yet...looking into it...
>
>Unfortunate behavior when probing pre-1970 dates, maybe?


Indeed that was the problem. Attached patch fixes the issue here and for
Merlin :-)

I've also figured out why it always worked for me. When in the western
europe timezone, the bug does not show up (probably because we don't
probe those dates). When I set my system to US Eastern, it broke.


//Magnus

Attachment

Re: [pgsql-hackers-win32] [HACKERS] win32 crash in initdb

From
Tom Lane
Date:
"Magnus Hagander" <mha@sollentuna.net> writes:
> Indeed that was the problem. Attached patch fixes the issue here and for
> Merlin :-)

This is not a good patch because it will treat the predictable pre-1970
failure as meaning the TZ should be rejected entirely.  What we want to
do is treat a null result as a non-match and score the TZ according to
the number of prior successful matches.

            regards, tom lane