]> granicus.if.org Git - php/commit
Enhance handling of CP932 text encoding
authorAlex Dowad <alexinbeijing@gmail.com>
Sun, 4 Oct 2020 20:29:34 +0000 (22:29 +0200)
committerAlex Dowad <alexinbeijing@gmail.com>
Wed, 25 Nov 2020 17:52:19 +0000 (19:52 +0200)
commit2759874a4250e45f25a1807cfaed7ab5bc07ae14
treeef1f03695ed4c3b45253a8a004215dfa123d7d2b
parentb489c1bc4d3a6c8abfc410bcdbf0aeb7ffc00246
Enhance handling of CP932 text encoding

- Don't allow control characters to appear in the middle of a multi-byte
  character. (This was a strange feature of mbstring; it doesn't make much
  sense, and iconv doesn't allow it.)
- Treat truncated multi-byte characters as an error.
ext/mbstring/libmbfl/filters/mbfilter_cp932.c
ext/mbstring/tests/cp932_encoding.phpt [new file with mode: 0644]
ext/mbstring/tests/data/CP932.txt [new file with mode: 0644]