diff options
author | Alexander Barkov <bar@mariadb.com> | 2022-04-13 17:17:17 +0400 |
---|---|---|
committer | Alexander Barkov <bar@mariadb.com> | 2022-04-21 09:51:11 +0400 |
commit | 2be617d869e614e2c0e7313fd77649a03c891cfd (patch) | |
tree | d1f788014294c6f451f98a36937b8eea0f76e4d7 /sql/sql_class.cc | |
parent | 5ba77222e9fe7af8ff403816b5338b18b342053c (diff) | |
download | mariadb-git-2be617d869e614e2c0e7313fd77649a03c891cfd.tar.gz |
MDEV-25243 ASAN heap-use-after-free in Item_func_sp::execute_impl upon concurrent view DDL and I_S query with view and function
Diffstat (limited to 'sql/sql_class.cc')
-rw-r--r-- | sql/sql_class.cc | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc index 4edf573e596..aa64e42e144 100644 --- a/sql/sql_class.cc +++ b/sql/sql_class.cc @@ -806,9 +806,6 @@ THD::THD(my_thread_id id, bool is_wsrep_applier) (my_hash_get_key) get_var_key, (my_hash_free_key) free_user_var, HASH_THREAD_SPECIFIC); - sp_proc_cache= NULL; - sp_func_cache= NULL; - /* For user vars replication*/ if (opt_bin_log) my_init_dynamic_array(&user_var_events, @@ -1353,8 +1350,7 @@ void THD::change_user(void) my_hash_init(&user_vars, system_charset_info, USER_VARS_HASH_SIZE, 0, 0, (my_hash_get_key) get_var_key, (my_hash_free_key) free_user_var, 0); - sp_cache_clear(&sp_proc_cache); - sp_cache_clear(&sp_func_cache); + sp_caches_clear(); } @@ -1410,8 +1406,7 @@ void THD::cleanup(void) #endif /* defined(ENABLED_DEBUG_SYNC) */ my_hash_free(&user_vars); - sp_cache_clear(&sp_proc_cache); - sp_cache_clear(&sp_func_cache); + sp_caches_clear(); auto_inc_intervals_forced.empty(); auto_inc_intervals_in_cur_stmt_for_binlog.empty(); |