MDEV-359: Fix another case where switch-off semisync could cause a race that ended with server crash.

This one was when the code releases and reaquires the lock with pthread_cond_wait() - and semisync is switched off meanwhile.
This commit is contained in:
unknown 2012-06-21 19:02:53 +02:00
commit e7362d457a
2 changed files with 2 additions and 1 deletions

View file

@ -1,7 +1,7 @@
--source include/have_semisync_plugin.inc
--source include/not_embedded.inc
--source include/have_binlog_format_mixed_or_statement.inc
--source include/have_debug_sync.inc
--source include/have_binlog_format_mixed_or_statement.inc
--source include/master-slave.inc
# MDEV-359: There was a server crash when the code first checks if semisync

View file

@ -744,6 +744,7 @@ int ReplSemiSyncMaster::commitTrx(const char* trx_wait_binlog_name,
must have been removed from ActiveTranx.
*/
assert(thd_killed(NULL) ||
!getMasterEnabled() ||
!active_tranxs_->is_tranx_end_pos(trx_wait_binlog_name,
trx_wait_binlog_pos));