mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
MDEV-10291 : Fix race condition in bootstrap
main thread may destroy mutexes that bootstrap is using in THD destructor.
This commit is contained in:
@ -1085,9 +1085,10 @@ void do_handle_bootstrap(THD *thd)
|
||||
handle_bootstrap_impl(thd);
|
||||
|
||||
end:
|
||||
in_bootstrap= FALSE;
|
||||
delete thd;
|
||||
|
||||
mysql_mutex_lock(&LOCK_thread_count);
|
||||
in_bootstrap = FALSE;
|
||||
mysql_cond_broadcast(&COND_thread_count);
|
||||
mysql_mutex_unlock(&LOCK_thread_count);
|
||||
|
||||
|
Reference in New Issue
Block a user