diff options
author | Monty <monty@mariadb.org> | 2015-08-24 14:42:07 +0300 |
---|---|---|
committer | Monty <monty@mariadb.org> | 2015-08-27 22:21:08 +0300 |
commit | 3cb578c001b2feabd2410f281d20eb6566371453 (patch) | |
tree | 4e3781e38f6531ea91ff127c024869c6b88c5849 /sql/sql_base.cc | |
parent | ba340d8c47657774ba6d69bfc918dbebaaef6086 (diff) | |
download | mariadb-git-3cb578c001b2feabd2410f281d20eb6566371453.tar.gz |
MDEV-6152: Remove calls to current_thd while creating Item
- Part 3: Adding mem_root to push_back() and push_front()
Other things:
- Added THD as an argument to some partition functions.
- Added memory overflow checking for XML tag's in read_xml()
Diffstat (limited to 'sql/sql_base.cc')
-rw-r--r-- | sql/sql_base.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/sql_base.cc b/sql/sql_base.cc index 7afe167738b..a97827bae88 100644 --- a/sql/sql_base.cc +++ b/sql/sql_base.cc @@ -7442,12 +7442,12 @@ store_natural_using_join_columns(THD *thd, TABLE_LIST *natural_using_join, nj_col_1= it_1.get_natural_column_ref(); if (nj_col_1->is_common) { - natural_using_join->join_columns->push_back(nj_col_1); + natural_using_join->join_columns->push_back(nj_col_1, thd->mem_root); /* Reset the common columns for the next call to mark_common_columns. */ nj_col_1->is_common= FALSE; } else - non_join_columns->push_back(nj_col_1); + non_join_columns->push_back(nj_col_1, thd->mem_root); } /* @@ -7487,7 +7487,7 @@ store_natural_using_join_columns(THD *thd, TABLE_LIST *natural_using_join, { nj_col_2= it_2.get_natural_column_ref(); if (!nj_col_2->is_common) - non_join_columns->push_back(nj_col_2); + non_join_columns->push_back(nj_col_2, thd->mem_root); else { /* Reset the common columns for the next call to mark_common_columns. */ @@ -8054,7 +8054,7 @@ bool setup_tables(THD *thd, Name_resolution_context *context, { List_iterator_fast <TABLE_LIST> ti(select_lex->leaf_tables_prep); while ((table_list= ti++)) - leaves.push_back(table_list); + leaves.push_back(table_list, thd->mem_root); } while ((table_list= ti++)) |