This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
[perl #87336] lc/uc(first) fail to taint the returned string
authorFather Chrysostomos <sprout@cpan.org>
Thu, 31 Mar 2011 13:28:49 +0000 (06:28 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Thu, 31 Mar 2011 13:28:49 +0000 (06:28 -0700)
commit539689e74a3bcb04d29e4cd9396de91a81045b99
tree06bda337e524215a894848863bc99947114a7a26
parent968ee499ff66c6dcd466884030cb185844f2d94f
[perl #87336] lc/uc(first) fail to taint the returned string

This bug was caused by change 28011 (ec9af7d), which stopped pp_lc
from using sv_setsv_flags, thereby bypassing these two lines at the
end of that function:
    if (SvTAINTED(sstr))
SvTAINT(dstr);

Change 28012 (6730619) did exactly the same thing to pp_uc.

28013 (d54190f) broke ucfirst and lcfirst.

This commit simply puts that taint logic at the end of the pp_*
functions.
pp.c
t/op/taint.t