Details
-
Type:
Bug
-
Status: Open
-
Priority:
Minor
-
Resolution: Unresolved
-
Affects Version/s: 5.3.12, 5.5.39, 10.0.13
-
Fix Version/s: 10.0
-
Component/s: None
-
Labels:None
Description
MariaDB [test]> SELECT HEX(_big5 0xC840), HEX(QUOTE(_big5 0xC840)); +-------------------+--------------------------+ | HEX(_big5 0xC840) | HEX(QUOTE(_big5 0xC840)) | +-------------------+--------------------------+ | C840 | NULL | +-------------------+--------------------------+ 1 row in set (0.00 sec)
The result for in the second column is wrong.
The expected result is C840, similar to the first column.
The problem happens because Item_func_quote::val_str()
uses an mb_wc()..wc_mb() loop, which breaks and returns
null on unassigned characters.
The loop should be fixed to use a native non-Unicode API instead, e.g. ismbchar().
Gliffy Diagrams
Attachments
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions