Commit 57f824b0 authored by Sergei Golubchik's avatar Sergei Golubchik

post-merge fixes

sql/slave.cc:
  add mutex protection, like in sql_parse.cc
parent 0a8c9b98
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
# #
############################################################################## ##############################################################################
#innodb_bug53756 : Waiting for merge with Percona Server; bug fixed in innodb_plugin in MySQL 5.1.50 innodb_bug13635833: Disabled until merging with XtraDB 5.1.63
innodb-lock: Disabled until merging with XtraDB 5.1.60 innodb-lock: Disabled until merging with XtraDB 5.1.60
innodb_replace: Disabled until merging with XtraDB 5.1.60 innodb_replace: Disabled until merging with XtraDB 5.1.60
...@@ -10,7 +10,10 @@ ...@@ -10,7 +10,10 @@
# #
############################################################################## ##############################################################################
innodb_bug13635833: Disabled until merging with XtraDB 5.1.63
innodb_bug52745: Disabled as this has valgrind failures (also in MySQL 5.1.50) innodb_bug52745: Disabled as this has valgrind failures (also in MySQL 5.1.50)
innodb-index: Disabled until merging with XtraDB 5.1.60 innodb-index: Disabled until merging with XtraDB 5.1.60
innodb-lock: Disabled until merging with XtraDB 5.1.60 innodb-lock: Disabled until merging with XtraDB 5.1.60
innodb_replace: Disabled until merging with XtraDB 5.1.60 innodb_replace: Disabled until merging with XtraDB 5.1.60
innodb-blob: Disabled until merging with XtraDB 5.1.63
...@@ -3,7 +3,6 @@ ...@@ -3,7 +3,6 @@
# columns are stored off-page. # columns are stored off-page.
--source include/have_innodb_plugin.inc --source include/have_innodb_plugin.inc
skip Not fixed in XtraDB yet;
# DEBUG_SYNC must be compiled in. # DEBUG_SYNC must be compiled in.
--source include/have_debug_sync.inc --source include/have_debug_sync.inc
......
...@@ -1451,7 +1451,9 @@ Waiting for the slave SQL thread to free enough relay log space"); ...@@ -1451,7 +1451,9 @@ Waiting for the slave SQL thread to free enough relay log space");
#endif #endif
if (rli->sql_force_rotate_relay) if (rli->sql_force_rotate_relay)
{ {
pthread_mutex_lock(&active_mi->data_lock);
rotate_relay_log(rli->mi); rotate_relay_log(rli->mi);
pthread_mutex_unlock(&active_mi->data_lock);
rli->sql_force_rotate_relay= false; rli->sql_force_rotate_relay= false;
} }
...@@ -4531,7 +4533,6 @@ int rotate_relay_log(Master_info* mi) ...@@ -4531,7 +4533,6 @@ int rotate_relay_log(Master_info* mi)
DBUG_ENTER("rotate_relay_log"); DBUG_ENTER("rotate_relay_log");
Relay_log_info* rli= &mi->rli; Relay_log_info* rli= &mi->rli;
int error= 0; int error= 0;
safe_mutex_assert_owner(&mi->data_lock);
/* /*
We need to test inited because otherwise, new_file() will attempt to lock We need to test inited because otherwise, new_file() will attempt to lock
...@@ -4559,7 +4560,10 @@ int rotate_relay_log(Master_info* mi) ...@@ -4559,7 +4560,10 @@ int rotate_relay_log(Master_info* mi)
output in SHOW SLAVE STATUS meanwhile. So we harvest now. output in SHOW SLAVE STATUS meanwhile. So we harvest now.
If the log is closed, then this will just harvest the last writes, probably If the log is closed, then this will just harvest the last writes, probably
0 as they probably have been harvested. 0 as they probably have been harvested.
Note that it needs to be protected by mi->data_lock.
*/ */
safe_mutex_assert_owner(&mi->data_lock);
rli->relay_log.harvest_bytes_written(&rli->log_space_total); rli->relay_log.harvest_bytes_written(&rli->log_space_total);
end: end:
DBUG_RETURN(error); DBUG_RETURN(error);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment