diff options
author | Michael Widenius <monty@askmonty.org> | 2011-05-10 18:17:43 +0300 |
---|---|---|
committer | Michael Widenius <monty@askmonty.org> | 2011-05-10 18:17:43 +0300 |
commit | f34be1893892745b5b1a7a099eab4ad8e9ac8641 (patch) | |
tree | d7eed818fd8b648e5eabe0dbad53e61665d8dc37 /sql/event_queue.cc | |
parent | e843297d128b165125d17aab8958f7ca91808923 (diff) | |
parent | 8882d71f3f1dd03ef98d072def39b29e6a03f5b8 (diff) | |
download | mariadb-git-f34be1893892745b5b1a7a099eab4ad8e9ac8641.tar.gz |
Merge with MariaDB 5.2
Diffstat (limited to 'sql/event_queue.cc')
-rw-r--r-- | sql/event_queue.cc | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sql/event_queue.cc b/sql/event_queue.cc index 2a354fe6cfd..c551cf74095 100644 --- a/sql/event_queue.cc +++ b/sql/event_queue.cc @@ -748,12 +748,14 @@ Event_queue::cond_wait(THD *thd, struct timespec *abstime, const char* msg, thd->enter_cond(&COND_queue_state, &LOCK_event_queue, msg); - DBUG_PRINT("info", ("pthread_cond_%swait", abstime? "timed":"")); - if (!abstime) - pthread_cond_wait(&COND_queue_state, &LOCK_event_queue); - else - pthread_cond_timedwait(&COND_queue_state, &LOCK_event_queue, abstime); - + if (!thd->killed) + { + DBUG_PRINT("info", ("pthread_cond_%swait", abstime ? "timed" : "")); + if (!abstime) + pthread_cond_wait(&COND_queue_state, &LOCK_event_queue); + else + pthread_cond_timedwait(&COND_queue_state, &LOCK_event_queue, abstime); + } mutex_last_locked_in_func= func; mutex_last_locked_at_line= line; mutex_queue_data_locked= TRUE; |