diff options
author | Zefram <zefram@fysh.org> | 2018-02-16 17:20:34 +0000 |
---|---|---|
committer | Zefram <zefram@fysh.org> | 2018-02-16 17:20:34 +0000 |
commit | fed9fe5b48ccdffef9065a03c12c237cc7418de6 (patch) | |
tree | da6bbd7364cc5149d52754a22c10e2f3fead710d /ext/File-DosGlob | |
parent | 4bd13559a0807d1dfa3c0ebf7d8807b318cdd711 (diff) | |
download | perl-fed9fe5b48ccdffef9065a03c12c237cc7418de6.tar.gz |
don't clobber file bytes in :encoding layer
The PerlIO::encoding layer, when used on input, was creating an SvLEN==0
scalar pointing into the byte buffer, to pass to the ->decode method
of the encoding object. Since the method mutates this scalar, for some
encodings this led to mutating the byte buffer, and depending on where
it came from that might be something visible elsewhere that should not
be mutated. Remove the code for the SvLEN==0 scalar, instead always
using the alternate code that would copy the bytes into a separate buffer
owned by the scalar. Fixes [perl #132833].
Diffstat (limited to 'ext/File-DosGlob')
0 files changed, 0 insertions, 0 deletions