Re: Getting server crash on Windows when using ICU collation

From: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
To: Ashutosh Sharma <ashu(dot)coek88(at)gmail(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Getting server crash on Windows when using ICU collation
Date: 2017-06-18 13:09:52
Message-ID: CAA4eK1JPm90Dr64teXMVW2vO9OB=PBY9=g7ujRGJ2EmOgduT+Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Jun 17, 2017 at 8:27 PM, Ashutosh Sharma <ashu(dot)coek88(at)gmail(dot)com> wrote:
> Hi,
>
> On Sat, Jun 17, 2017 at 6:38 PM, Peter Eisentraut
> <peter(dot)eisentraut(at)2ndquadrant(dot)com> wrote:
>> On 6/16/17 23:46, Amit Kapila wrote:
>>> I have just posted one way
>>> to determine if icu library has support for ucol_strcollUTF8, see if
>>> that sounds like a way forward to you.
>>
>> I'm not in a position to test such patches, so someone else will have to
>> take that on.
>

I can verify the patch on Win7 setup to which I have access if that helps.

> Well, I have tested it from my end. I've basically tried to test it by
> running multi-byte tests as Amit suggested and by verifing the things
> manually through debugger . And, i had mistakenly attached wrong patch
> in my earlier email. Here, i attach the correct patch.
>

Is it possible for you to once verify this patch with icu library
version where ucol_strcollUTF8 is not defined?

+ # get the icu version.
+ my $output = `uconv -V /? 2>&1`;
+ $? >> 8 == 0 or die "uconv command not found";

If we don't find unconv, isn't it better to fall back to non-UTF8
version rather than saying command not found?

+ print $o "#define HAVE_UCOL_STRCOLLUTF8 1\n"
+ if ($self->{ICUVersion} >= 50);

Indentation looks slightly odd, see the other usage in the same file.

--
With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2017-06-18 13:47:33 Re: Decimal64 and Decimal128
Previous Message Shubham Barai 2017-06-18 11:48:23 Re: GSoC 2017 : Patch for predicate locking in Gist index