diff options
author | Pali <pali@cpan.org> | 2018-02-10 13:41:19 +0100 |
---|---|---|
committer | Tony Cook <tony@develop-help.com> | 2019-09-02 10:21:55 +1000 |
commit | 27c41eac9877077f4ce636c417f5e3904a95754b (patch) | |
tree | 617c22332fa9992e3d5371d9871d1b61dd10894a /doop.c | |
parent | 423ce6234bb755185e783187da2b1fc06560ce8b (diff) | |
download | perl-27c41eac9877077f4ce636c417f5e3904a95754b.tar.gz |
Fix do_vecget and do_vecset to process GET magic only once
Diffstat (limited to 'doop.c')
-rw-r--r-- | doop.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -758,7 +758,7 @@ Perl_do_vecget(pTHX_ SV *sv, STRLEN offset, int size) Perl_croak(aTHX_ "Illegal number of bits in vec"); if (SvUTF8(sv)) { - if (Perl_sv_utf8_downgrade(aTHX_ sv, TRUE)) { + if (Perl_sv_utf8_downgrade_flags(aTHX_ sv, TRUE, 0)) { /* PVX may have changed */ s = (unsigned char *) SvPV_flags(sv, srclen, svpv_flags); } @@ -931,10 +931,10 @@ Perl_do_vecset(pTHX_ SV *sv) SV_GMAGIC | SV_UNDEF_RETURNS_NULL); if (SvUTF8(targ)) { /* This is handled by the SvPOK_only below... - if (!Perl_sv_utf8_downgrade(aTHX_ targ, TRUE)) + if (!Perl_sv_utf8_downgrade_flags(aTHX_ targ, TRUE, 0)) SvUTF8_off(targ); */ - (void) Perl_sv_utf8_downgrade(aTHX_ targ, TRUE); + (void) Perl_sv_utf8_downgrade_flags(aTHX_ targ, TRUE, 0); } (void)SvPOK_only(targ); |