buffer: fix transcode for single-byte enc to ucs2
Fix `buffer.transcode()` for transcoding from single-byte character encodings to UCS2. These would previously perform out-of-bounds reads due to an incorrect `sizeof()` expression. Fixes: https://github.com/nodejs/node/issues/9834 PR-URL: https://github.com/nodejs/node/pull/9838 Reviewed-By:Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Trevor Norris <trev.norris@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
parent
18cf668d
Please register or sign in to comment