Open
Description
Hi, thanks very much for your work on this repository, it's incredibly useful. We use it as the main character encoding library for CyberChef.
We've recently noticed an issue when trying to encode into ISO 2022 JIS Japanese
where only null bytes are returned.
The affected CP numbers are 50220
, 50221
and 50222
.
Example code
import cptable from "codepage";
cptable.utils.encode(50220, "こんにちは");
Expected output
Uint8Array(10) [164, 179, 164, 243, 164, 203, 164, 193, 164, 207]
Actual output
Uint8Array(5) [0, 0, 0, 0, 0]
Can you shed any light on this behaviour?
Metadata
Metadata
Assignees
Labels
No labels