summaryrefslogtreecommitdiff
path: root/sql/item_cmpfunc.cc
diff options
context:
space:
mode:
authorEugene Kosov <claprix@yandex.ru>2020-10-05 20:01:05 +0300
committerEugene Kosov <claprix@yandex.ru>2020-10-05 20:02:22 +0300
commit01ffccd6a4ec2af645b81bcfef8a02f031a492e5 (patch)
treeb470d1315134de006fd652fe193f5d38a1647afa /sql/item_cmpfunc.cc
parent0aef658dfab527bf91e805589230f907e57bc6b4 (diff)
downloadmariadb-git-01ffccd6a4ec2af645b81bcfef8a02f031a492e5.tar.gz
UBSAN: UndefinedBehaviorSanitizer: undefined-behavior ../sql/item_cmpfunc.cc:3650:14
Diffstat (limited to 'sql/item_cmpfunc.cc')
-rw-r--r--sql/item_cmpfunc.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/sql/item_cmpfunc.cc b/sql/item_cmpfunc.cc
index 03648a323d5..69c7eb33852 100644
--- a/sql/item_cmpfunc.cc
+++ b/sql/item_cmpfunc.cc
@@ -4153,8 +4153,11 @@ void Item_func_in::fix_after_pullout(st_select_lex *new_parent, Item **ref,
eval_not_null_tables(NULL);
}
-static int srtcmp_in(CHARSET_INFO *cs, const String *x,const String *y)
+static int srtcmp_in(const void *cs_, const void *x_, const void *y_)
{
+ const CHARSET_INFO *cs= static_cast<const CHARSET_INFO *>(cs_);
+ const String *x= static_cast<const String *>(x_);
+ const String *y= static_cast<const String *>(y_);
return cs->coll->strnncollsp(cs,
(uchar *) x->ptr(),x->length(),
(uchar *) y->ptr(),y->length());