diff options
author | Alexander Barkov <bar@mariadb.org> | 2017-10-03 07:54:22 +0400 |
---|---|---|
committer | Alexander Barkov <bar@mariadb.org> | 2017-10-03 08:03:51 +0400 |
commit | fcf631eafb7455bafde3847b4ab13a6ff245a703 (patch) | |
tree | cfdd7142cc132162332dcd640c8719ec3902dbbd /sql/sp_rcontext.h | |
parent | 8ae8cd63485eb063de0b70ea6f3acf7102a61fef (diff) | |
download | mariadb-git-fcf631eafb7455bafde3847b4ab13a6ff245a703.tar.gz |
A cleanup for MDEV-10914 ROW data type for stored routine variables
Changing datatypes for:
- Item_spvar_args::m_table
- sp_rcontext::m_var_table
- return value of create_virtual_tmp_table()
from TABLE* to Virtual_tmp_table*
Advantages:
- Stricter data type control
- Removing the duplicate code (a loop with free_blobs)
from destructors ~sp_rcontext() and ~Item_spvar_args(),
using "delete m_(var_)table" in both instead.
- Using Virtual_tmp_table::delete makes the code call Field::delete,
which calls TRASH() for the freed fields,
which is good for valgrind test runs.
Diffstat (limited to 'sql/sp_rcontext.h')
-rw-r--r-- | sql/sp_rcontext.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/sp_rcontext.h b/sql/sp_rcontext.h index 93c8cacc70a..9a4a8e27032 100644 --- a/sql/sp_rcontext.h +++ b/sql/sp_rcontext.h @@ -34,6 +34,7 @@ class sp_instr_cpush; class Query_arena; class sp_head; class Item_cache; +class Virtual_tmp_table; /* @@ -365,7 +366,7 @@ private: const sp_pcontext *m_root_parsing_ctx; /// Virtual table for storing SP-variables. - TABLE *m_var_table; + Virtual_tmp_table *m_var_table; /// Collection of Item_field proxies, each of them points to the /// corresponding field in m_var_table. |