Commit 6f530c63 authored by Sergei Golubchik's avatar Sergei Golubchik

cleanup: specify memroot explicitly in `new Explain_xxx`

parent 1cc67e09
......@@ -24771,7 +24771,7 @@ void save_agg_explain_data(JOIN *join, Explain_select *xpl_sel)
{
// Each aggregate means a temp.table
prev_node= node;
node= new Explain_aggr_tmp_table;
node= new (thd->mem_root) Explain_aggr_tmp_table;
node->child= prev_node;
if (join_tab->window_funcs_step)
......@@ -24791,14 +24791,14 @@ void save_agg_explain_data(JOIN *join, Explain_select *xpl_sel)
if (join_tab->distinct)
{
prev_node= node;
node= new Explain_aggr_remove_dups;
node= new (thd->mem_root) Explain_aggr_remove_dups;
node->child= prev_node;
}
if (join_tab->filesort)
{
Explain_aggr_filesort *eaf =
new Explain_aggr_filesort(thd->mem_root, is_analyze, join_tab->filesort);
new (thd->mem_root) Explain_aggr_filesort(thd->mem_root, is_analyze, join_tab->filesort);
prev_node= node;
node= eaf;
node->child= prev_node;
......
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