Commit 0ac0bc8c authored by Sergei Petrunia's avatar Sergei Petrunia

MDEV-21341: Fix optimizer-related UBSAN failures, part #1:

Fix wrong typecast
parent 3d988922
...@@ -14157,7 +14157,7 @@ static COND* substitute_for_best_equal_field(THD *thd, JOIN_TAB *context_tab, ...@@ -14157,7 +14157,7 @@ static COND* substitute_for_best_equal_field(THD *thd, JOIN_TAB *context_tab,
} }
} }
else if (cond->type() == Item::FUNC_ITEM && else if (cond->type() == Item::FUNC_ITEM &&
((Item_cond*) cond)->functype() == Item_func::MULT_EQUAL_FUNC) ((Item_func*) cond)->functype() == Item_func::MULT_EQUAL_FUNC)
{ {
item_equal= (Item_equal *) cond; item_equal= (Item_equal *) cond;
item_equal->sort(&compare_fields_by_table_order, table_join_idx); item_equal->sort(&compare_fields_by_table_order, table_join_idx);
......
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