Commit b088609a authored by Alexander Barkov's avatar Alexander Barkov

A clean-up for the previous patch

parent 1427e1db
......@@ -5954,6 +5954,13 @@ SET @arg00=_binary 0xFF;
EXECUTE stmt USING @arg00;
ERROR HY000: Invalid utf8 character string: 'FF'
DEALLOCATE PREPARE stmt;
SET NAMES latin1;
PREPARE stmt FROM "SELECT CONCAT(_utf8'a' COLLATE utf8_unicode_ci, ?)";
EXECUTE stmt USING @no_such_var;
CONCAT(_utf8'a' COLLATE utf8_unicode_ci, ?)
NULL
DEALLOCATE PREPARE stmt;
SET NAMES utf8;
#
# End of 10.0 tests
#
......@@ -1675,6 +1675,11 @@ SET @arg00=_binary 0xFF;
--error ER_INVALID_CHARACTER_STRING
EXECUTE stmt USING @arg00;
DEALLOCATE PREPARE stmt;
SET NAMES latin1;
PREPARE stmt FROM "SELECT CONCAT(_utf8'a' COLLATE utf8_unicode_ci, ?)";
EXECUTE stmt USING @no_such_var;
DEALLOCATE PREPARE stmt;
SET NAMES utf8;
--echo #
--echo # End of 10.0 tests
......
......@@ -1274,6 +1274,8 @@ Item *Item_param::safe_charset_converter(CHARSET_INFO *tocs)
*/
if (const_item())
{
if (state == NULL_VALUE)
return this;
uint cnv_errors;
String *ostr= val_str(&cnvstr);
if (!needs_charset_converter(tocs))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment