summaryrefslogtreecommitdiff
path: root/sql/item_cmpfunc.cc
diff options
context:
space:
mode:
authorOleksandr Byelkin <sanja@mariadb.com>2017-11-13 16:30:02 +0100
committerOleksandr Byelkin <sanja@mariadb.com>2017-11-14 10:49:46 +0100
commit2913f615f050f356f7be178e5d91650b86b33e4e (patch)
tree216193d0dabedf52c35966d6bd60b9bea3c81995 /sql/item_cmpfunc.cc
parentc0e10f375ad619d825ef7c21232cf5946bdf5be7 (diff)
downloadmariadb-git-2913f615f050f356f7be178e5d91650b86b33e4e.tar.gz
MDEV-8949: COLUMN_CREATE unicode name breakage
Use utf-mb4 if it is possible.
Diffstat (limited to 'sql/item_cmpfunc.cc')
-rw-r--r--sql/item_cmpfunc.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/sql/item_cmpfunc.cc b/sql/item_cmpfunc.cc
index b086b084f97..807ce828131 100644
--- a/sql/item_cmpfunc.cc
+++ b/sql/item_cmpfunc.cc
@@ -6642,7 +6642,7 @@ longlong Item_func_dyncol_exists::val_int()
null_value= 1;
return 1;
}
- if (my_charset_same(nm->charset(), &my_charset_utf8_general_ci))
+ if (my_charset_same(nm->charset(), DYNCOL_UTF))
{
buf.str= (char *) nm->ptr();
buf.length= nm->length();
@@ -6652,11 +6652,11 @@ longlong Item_func_dyncol_exists::val_int()
uint strlen;
uint dummy_errors;
buf.str= (char *)sql_alloc((strlen= nm->length() *
- my_charset_utf8_general_ci.mbmaxlen + 1));
+ DYNCOL_UTF->mbmaxlen + 1));
if (buf.str)
{
buf.length=
- copy_and_convert(buf.str, strlen, &my_charset_utf8_general_ci,
+ copy_and_convert(buf.str, strlen, DYNCOL_UTF,
nm->ptr(), nm->length(), nm->charset(),
&dummy_errors);
}