diff options
author | Sergei Golubchik <sergii@pisem.net> | 2010-11-25 18:17:28 +0100 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2010-11-25 18:17:28 +0100 |
commit | 65ca700def99289cc31a7040537f5aa6e12bf485 (patch) | |
tree | 97b3a07299b626c519da0e80c122b5b79b933914 /sql/event_scheduler.cc | |
parent | 2ab57de38d13d927ddff2d51aed4af34e13998f5 (diff) | |
parent | 6e5bcca7935d3c62f84bb640e5357664a210ee12 (diff) | |
download | mariadb-git-65ca700def99289cc31a7040537f5aa6e12bf485.tar.gz |
merge.
checkpoint.
does not compile.
Diffstat (limited to 'sql/event_scheduler.cc')
-rw-r--r-- | sql/event_scheduler.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sql/event_scheduler.cc b/sql/event_scheduler.cc index aa4d376d86e..bf16ddcb05a 100644 --- a/sql/event_scheduler.cc +++ b/sql/event_scheduler.cc @@ -349,6 +349,14 @@ Event_scheduler::Event_scheduler(Event_queue *queue_arg) mysql_mutex_init(key_event_scheduler_LOCK_scheduler_state, &LOCK_scheduler_state, MY_MUTEX_INIT_FAST); mysql_cond_init(key_event_scheduler_COND_state, &COND_state, NULL); + +#ifdef SAFE_MUTEX + /* Ensure right mutex order */ + mysql_mutex_lock(&LOCK_scheduler_state); + mysql_mutex_lock(&LOCK_global_system_variables); + mysql_mutex_unlock(&LOCK_global_system_variables); + mysql_mutex_unlock(&LOCK_scheduler_state); +#endif } |