summaryrefslogtreecommitdiff
path: root/sql/event_scheduler.cc
diff options
context:
space:
mode:
authorEugene Kosov <claprix@yandex.ru>2020-04-30 20:06:26 +0300
committerEugene Kosov <claprix@yandex.ru>2020-05-05 18:13:31 +0300
commit89ff4176c125f5993aba0732e52102227577ed96 (patch)
tree42980e30d3f4f02b09b0fda80790f7241fd699f4 /sql/event_scheduler.cc
parent90aad47dd9f28101b1d2c4a01c2a10db5ad5f426 (diff)
downloadmariadb-git-89ff4176c125f5993aba0732e52102227577ed96.tar.gz
MDEV-22437 make THR_THD* variable thread_local
Now all access goes through _current_thd() and set_current_thd() functions. Some functions like THD::store_globals() can not fail now.
Diffstat (limited to 'sql/event_scheduler.cc')
-rw-r--r--sql/event_scheduler.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/event_scheduler.cc b/sql/event_scheduler.cc
index 0e8e4826939..e842d95e3b0 100644
--- a/sql/event_scheduler.cc
+++ b/sql/event_scheduler.cc
@@ -128,11 +128,12 @@ bool
post_init_event_thread(THD *thd)
{
(void) init_new_connection_handler_thread();
- if (init_thr_lock() || thd->store_globals())
+ if (init_thr_lock())
{
thd->cleanup();
return TRUE;
}
+ thd->store_globals();
return FALSE;
}