1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-24 19:42:23 +03:00

MDEV-9455: [ERROR] mysqld got signal 11

Switch MEM_ROOT to non-prune_partitions() during optimizing subselect.
This commit is contained in:
Oleksandr Byelkin
2017-02-17 13:37:18 +01:00
parent 1b7aae90fb
commit 5ddfcb05ca
3 changed files with 191 additions and 2 deletions

View File

@ -7500,8 +7500,15 @@ static SEL_TREE *get_mm_tree(RANGE_OPT_PARAM *param,COND *cond)
if (cond_func->functype() == Item_func::BETWEEN ||
cond_func->functype() == Item_func::IN_FUNC)
inv= ((Item_func_opt_neg *) cond_func)->negated;
else if (cond_func->select_optimize() == Item_func::OPTIMIZE_NONE)
DBUG_RETURN(0);
else
{
MEM_ROOT *tmp_root= param->mem_root;
param->thd->mem_root= param->old_root;
Item_func::optimize_type opt_res= cond_func->select_optimize();
param->thd->mem_root= tmp_root;
if (opt_res == Item_func::OPTIMIZE_NONE)
DBUG_RETURN(0);
}
param->cond= cond;