Re: Unexpected plperl difference between 8.4 and 9.1 - Mailing list pgsql-hackers

From Alex Hunsaker
Subject Re: Unexpected plperl difference between 8.4 and 9.1
Date
Msg-id CAFaPBrSD4fOJqHBiZfWd5+8gnovirpiDJHftrNvA_gX5w8tUvg@mail.gmail.com
Whole thread Raw
In response to Re: Unexpected plperl difference between 8.4 and 9.1  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Responses Re: Unexpected plperl difference between 8.4 and 9.1
List pgsql-hackers


On Mon, Aug 20, 2012 at 10:14 AM, Alvaro Herrera <alvherre@2ndquadrant.com> wrote:
Excerpts from Alex Hunsaker's message of lun ago 20 12:03:11 -0400 2012:
> On Sun, Aug 19, 2012 at 2:26 PM, Joel Jacobson <joel@trustly.com> wrote:
>
> > After upgrading from 8.4 to 9.1, one of my plperl functions stopped
> > working properly.

I can reproduce the failure with 5.14.2


Me too, however it works for me with 5.14.1, looking more like a strange perl bug.

I've tried reproducing this in straight perl but I don't think I can without using some C code, specifically the call to SvPVutf8 in sv2cstr() seems to be the culprit. If I change that to SvPV() it seems to work. Im wondering if there is some strange caching of utf8 strings going on that =~ m// is not clearing.

Ill keep digging and hopefully be able to narrow it down to a commit between 5.14.1 and 5.14.2 so we can understand more whats going here.

pgsql-hackers by date:

Previous
From: Tatsuo Ishii
Date:
Subject: Re: Is this an appropriate item?
Next
From: Tom Lane
Date:
Subject: Re: Unexpected plperl difference between 8.4 and 9.1