-
unknown authored
When InnoDB compares varchar field in ucs2 with given key using bin collation, it calls my_strnncollsp_ucs2_bin() to perform comparison. Because field length was lesser than length of key field should be padded with trailing spaces in order to get correct result. Because my_strnncollsp_ucs2_bin() was calling my_strnncollp_ucs2_bin(), which doesn't pads field, wrong comparison result was returned. This results in wrong result set. my_strnncollsp_ucs2_bin() now compares fields like my_strnncollsp_ucs2 do, but using binary collation. mysql-test/t/ctype_ucs.test: Test case for bug#14583 Wrong my_strnncollsp_ucs2_bin() behaviour results in skipping correct records. mysql-test/r/ctype_ucs.result: Test case for bug#14583 Wrong my_strnncollsp_ucs2_bin() behaviour results in skipping correct records. strings/ctype-ucs2.c: Fix bug#14583 Wrong my_strnncollsp_ucs2_bin() behaviour results in skipping correct records.my_strnncollsp_ucs2_bin() now compares fields like my_strnncollsp_ucs2 do, but using binary collation.
9a128b97