https://bugzilla.redhat.com/show_bug.cgi?id=970913

            Bug ID: 970913
           Summary: perl-5.18: UTF-8-downgraded variables are not properly
                    interpolated in a regular expression
           Product: Fedora
           Version: rawhide
         Component: perl
          Severity: unspecified
          Priority: unspecified
          Assignee: mmasl...@redhat.com
          Reporter: ppi...@redhat.com
        QA Contact: extras...@fedoraproject.org
                CC: cw...@alumni.drew.edu, iarn...@gmail.com,
                    jples...@redhat.com, ka...@ucw.cz, lkund...@v3.sk,
                    mmasl...@redhat.com,
                    perl-devel@lists.fedoraproject.org, ppi...@redhat.com,
                    psab...@redhat.com, rc040...@freenet.de,
                    tcall...@redhat.com

$ perl -e 'utf8::upgrade(my $u = "\x{e5}"); utf8::downgrade(my $d =
"\x{e5}"); qr{$u $d}'
Malformed UTF-8 character (1 byte, need 3, after start byte 0xe5) in
regexp compilation at -e line 1.
Malformed UTF-8 character (1 byte, need 3, after start byte 0xe5) in
regexp compilation at -e line 1.

This bug has been reported to upstream
<https://rt.perl.org/rt3//Public/Bug/Display.html?id=118297> and fixed with
upstream commit:

commit b8372399b387c0e276aee3d41b3c7833dd08087b
Author: Dagfinn Ilmari Mannsåker <ilm...@ilmari.org>
Date:   Tue Jun 4 18:15:24 2013 +0100

    [perl #118297] Fix interpolating downgraded variables into upgraded regexp

    The code alredy upgraded the pattern if interpolating an upgraded
    string into it, but not vice versa.  Just use sv_catsv_nomg() instead
    of sv_catpvn_nomg(), so that it can upgrade as necessary.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug 
https://bugzilla.redhat.com/token.cgi?t=1JpTVZjcZ0&a=cc_unsubscribe
--
Fedora Extras Perl SIG
http://www.fedoraproject.org/wiki/Extras/SIGs/Perl
perl-devel mailing list
perl-devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/perl-devel

Reply via email to