ZF-5567: Investigate Zend_Json_Encoder/Decoder::encodeUnicodeString failure on UTF-8 Chars > 65535
Description
It seems that the algorithms for Unicode Encoding and/or Decoding fail on characters 65535.
It seems that the algorithms for Unicode Encoding and/or Decoding fail on characters 65535.
Comments
Posted by Pádraic Brady (padraic) on 2009-12-23T05:40:05.000+0000
Moving Priority to Major from N/A (may have buried it in filters). May have been recently duplicated.
Posted by Pádraic Brady (padraic) on 2009-12-23T05:41:20.000+0000
Benjamin, any chance you could expand on the description perhaps with a test case or example?
Posted by Pádraic Brady (padraic) on 2011-08-20T12:21:09.000+0000
Test with higher Unicode (e.g. Gothic range) but could locate no issues. Translation to/from array/strings using a mix of native and Zend_Json functions showed no translation difficulty. Given lack of reporter tests, I'm closing this as a non-issue.
Posted by Pádraic Brady (padraic) on 2011-08-20T12:34:34.000+0000
Of course, would help if my last test was written correctly... Reopening. Results in garbage text on conversion.
Posted by BitConstructor Co. Ltd. (bitconstructor) on 2012-05-03T13:00:35.000+0000
encodeUnicodeString misses the default case in the switch on line 458. This may break the conversion for not handled cases. I got the problem with the following string: คอนเสิร์ต ไผ่ พงศธร
The issue seems to occur less if I introduce the default case and copy the char as it is