summaryrefslogtreecommitdiff
path: root/plugin/semisync
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2012-03-27 16:16:44 +0200
committerSergei Golubchik <sergii@pisem.net>2012-03-27 16:16:44 +0200
commit3d0775e9af2fcf3fe92b7f19e299ea23068eca1e (patch)
treedb70f85e9f5489dc37448c674a83b890a9d96e62 /plugin/semisync
parent903ad7c94137f7c844cde03befc4ddd8e9713a3b (diff)
downloadmariadb-git-3d0775e9af2fcf3fe92b7f19e299ea23068eca1e.tar.gz
mdev-201 - Assertion `!thd->spcont' failed in net_send_error on server shutdown
bug in semisync plugin. It didn't check thd->killed before waiting on mysys->current_cond, and thus an attepmt to kill the thread (on shutdown) was lost plugin/semisync/semisync_master.cc: mdev:201 lp:962540
Diffstat (limited to 'plugin/semisync')
-rw-r--r--plugin/semisync/semisync_master.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/plugin/semisync/semisync_master.cc b/plugin/semisync/semisync_master.cc
index 7504697a21f..9e857f83d39 100644
--- a/plugin/semisync/semisync_master.cc
+++ b/plugin/semisync/semisync_master.cc
@@ -626,7 +626,7 @@ int ReplSemiSyncMaster::commitTrx(const char* trx_wait_binlog_name,
(int)is_on());
}
- while (is_on())
+ while (is_on() && !thd_killed(NULL))
{
if (reply_file_name_inited_)
{
@@ -743,7 +743,8 @@ int ReplSemiSyncMaster::commitTrx(const char* trx_wait_binlog_name,
At this point, the binlog file and position of this transaction
must have been removed from ActiveTranx.
*/
- assert(!active_tranxs_->is_tranx_end_pos(trx_wait_binlog_name,
+ assert(thd_killed(NULL) ||
+ !active_tranxs_->is_tranx_end_pos(trx_wait_binlog_name,
trx_wait_binlog_pos));
/* Update the status counter. */