diff options
author | Sergei Golubchik <serg@mariadb.org> | 2021-02-05 14:59:27 +0100 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2021-02-12 18:14:20 +0100 |
commit | 9703cffa8cb57e2fe29719f4aae3282bfae82878 (patch) | |
tree | 9e9d6a7dcf0f7ceff47091b47465a06613fc2dcb /sql/sql_class.h | |
parent | 259a1902a066d01547e5d70ba0e4837d1be62e7b (diff) | |
download | mariadb-git-9703cffa8cb57e2fe29719f4aae3282bfae82878.tar.gz |
don't take mutexes conditionally
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r-- | sql/sql_class.h | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h index be61a4047ec..39d6ec1027f 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -3309,18 +3309,11 @@ public: void awake_no_mutex(killed_state state_to_set); void awake(killed_state state_to_set) { - bool wsrep_on_local= variables.wsrep_on; - /* - mutex locking order (LOCK_thd_data - LOCK_thd_kill)) requires - to grab LOCK_thd_data here - */ - if (wsrep_on_local) - mysql_mutex_lock(&LOCK_thd_data); + mysql_mutex_lock(&LOCK_thd_data); mysql_mutex_lock(&LOCK_thd_kill); awake_no_mutex(state_to_set); mysql_mutex_unlock(&LOCK_thd_kill); - if (wsrep_on_local) - mysql_mutex_unlock(&LOCK_thd_data); + mysql_mutex_unlock(&LOCK_thd_data); } void abort_current_cond_wait(bool force); |