develooper Front page | perl.perl5.porters | Postings from April 2019

[perl #133928] POSIX::mblen() broken on threaded perls with glibc

Thread Next
James E Keenan via RT
April 2, 2019 21:38
[perl #133928] POSIX::mblen() broken on threaded perls with glibc
Message ID:
On Tue, 26 Mar 2019 19:56:17 GMT, wrote:
> On 3/26/19 1:26 PM, Niko Tyni wrote:
> > On Mon, Mar 25, 2019 at 02:14:35PM -0700, karl williamson via RT wrote:
> > 
> >> I need to apologize to Niko.  He had figured things out, and indeed his
> >> program is virtually the same as mine.  When I first read it, I didn't
> >> really understand the issue, and when I did understand it, I forgot to
> >> read the program again.  If I had, it would have saved me some effort.
> > 
> > Oh, no need to apologize! I could certainly have explained things clearer,
> > and must admit I was still a bit hazy on details at that point.
> > 
> > Too bad for the duplicate work, but I'm glad we arrived at the same
> > conclusion :)
> > 
> >> In thinking about it since, I'm unsure fhat openbsd needs to look at the
> >> third argument.  In their system there are only two locales (and you can
> >> see that in the trace as they are numbered 1 and 2).  One locale has all
> >> categories be C.  The other locale has LC_CTYPE be C.UTF-8.  To
> >> implement this properly, all one has to do is see if the mask parameter
> >> includes LC_CTYPE.  If not, do nothing.  If so, set the locale to 1 or 2
> >> depending on if the new name ends with UTF-8.  I believe this has the
> >> same effect as if one were to take into account the third parameter.
> > 
> > FWIW I also think this would work.
> > 
> > I guess the mb.t tests added in this ticket could use a skip/todo for
> > openbsd for as long as it has the current behaviour? See attached.
> > 
> I'm thinking that this bug in OpenBSD necessitates us not using the 
> POSIX 20008 calls, so I'll either change the hints file, or if this is a 
> problem on other systems too, write a Configure probe.
> In either event, these tests will start working without having to change 
> them.

Among our smoke-testing rigs ext/POSIX/t/mb.t is still experiencing failures on 2 OSes.  See:


HP-UX B.11.23/64:
James E Keenan (

via perlbug:  queue: perl5 status: open

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About