1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

Fix merge error on binlog_remove_pending_rows causing failure

on binlog_innodb_row test.
This commit is contained in:
Jan Lindström
2014-09-10 18:48:26 +03:00
parent b67e1d3c98
commit 595bcb7947
3 changed files with 14 additions and 22 deletions

View File

@@ -1083,6 +1083,13 @@ end:
DBUG_RETURN(error);
}
static inline TC_LOG *get_tc_log_implementation()
{
if (total_ha_2pc <= 1)
return &tc_log_dummy;
if (opt_bin_log)
return &mysql_bin_log;
return &tc_log_mmap;
}
#endif /* LOG_H */

View File

@@ -5204,27 +5204,12 @@ a file name for --log-bin-index option", opt_binlog_index_name);
}
#endif
/* if total_ha_2pc <= 1
tc_log = tc_log_dummy
else
if opt_bin_log == true
tc_log = mysql_bin_log
else
if WITH_WSREP
if WSREP_ON
tc_log = tc_log_dummy
else
tc_log = tc_log_mmap
else
tc_log=tc_log_mmap
*/
tc_log= (total_ha_2pc > 1 ? (opt_bin_log ?
(TC_LOG *) &mysql_bin_log :
IF_WSREP((WSREP_ON ? (TC_LOG *) &tc_log_dummy :
(TC_LOG *) &tc_log_mmap), (TC_LOG *) &tc_log_mmap)) :
(TC_LOG *) &tc_log_dummy);
tc_log= get_tc_log_implementation();
#ifdef WITH_WSREP
if (WSREP_ON && tc_log == &tc_log_mmap)
tc_log= &tc_log_dummy;
WSREP_DEBUG("Initial TC log open: %s",
(tc_log == &mysql_bin_log) ? "binlog" :
(tc_log == &tc_log_mmap) ? "mmap" :

View File

@@ -5793,8 +5793,8 @@ int THD::binlog_remove_pending_rows_event(bool clear_maps,
{
DBUG_ENTER("THD::binlog_remove_pending_rows_event");
IF_WSREP(!(WSREP_EMULATE_BINLOG(this) || mysql_bin_log.is_open()),
!mysql_bin_log.is_open());
if(IF_WSREP(!(WSREP_EMULATE_BINLOG(this) || mysql_bin_log.is_open()),
!mysql_bin_log.is_open()))
DBUG_RETURN(0);
/* Ensure that all events in a GTID group are in the same cache */