summaryrefslogtreecommitdiff
path: root/sql/log.cc
diff options
context:
space:
mode:
authorunknown <holyfoot@mysql.com>2006-04-27 15:07:36 +0500
committerunknown <holyfoot@mysql.com>2006-04-27 15:07:36 +0500
commiteae76a32b2e8798610b4719a5f67956625291257 (patch)
treef7ccd3b75989849bfd9dcff7f3c249dc33055fa3 /sql/log.cc
parent3ada0dd96f3c5d32a4f5a39cefb75bfd321029cd (diff)
parentca3277a87cf158d6e51b62cb8e0fb222e6cf883e (diff)
downloadmariadb-git-eae76a32b2e8798610b4719a5f67956625291257.tar.gz
Merge bk@192.168.21.1:mysql-5.1-new
into mysql.com:/home/hf/work/mysql-5.1.18518 include/my_global.h: Auto merged sql/log.cc: Auto merged sql/mysqld.cc: Auto merged sql/set_var.cc: Auto merged sql/sql_base.cc: Auto merged sql/sql_class.cc: Auto merged sql/sql_class.h: Auto merged sql/sql_parse.cc: Auto merged
Diffstat (limited to 'sql/log.cc')
-rw-r--r--sql/log.cc10
1 files changed, 10 insertions, 0 deletions
diff --git a/sql/log.cc b/sql/log.cc
index 818abe89e02..92cf8d2e73b 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -1084,12 +1084,16 @@ binlog_end_trans(THD *thd, binlog_trx_data *trx_data, Log_event *end_ev)
were, we would have to ensure that we're not ending a statement
inside a stored function.
*/
+#ifdef HAVE_ROW_BASED_REPLICATION
thd->binlog_flush_pending_rows_event(true);
+#endif
error= mysql_bin_log.write(thd, trans_log, end_ev);
}
else
{
+#ifdef HAVE_ROW_BASED_REPLICATION
thd->binlog_delete_pending_rows_event();
+#endif
}
/*
@@ -2613,6 +2617,7 @@ bool MYSQL_LOG::is_query_in_union(THD *thd, query_id_t query_id_param)
}
+#ifdef HAVE_ROW_BASED_REPLICATION
/*
These functions are placed in this file since they need access to
binlog_hton, which has internal linkage.
@@ -2790,6 +2795,7 @@ int MYSQL_LOG::flush_and_set_pending_rows_event(THD *thd, Rows_log_event* event)
DBUG_RETURN(error);
}
+#endif /*HAVE_ROW_BASED_REPLICATION*/
/*
Write an event to the binary log
@@ -2824,7 +2830,9 @@ bool MYSQL_LOG::write(Log_event *event_info)
*/
bool const end_stmt=
thd->prelocked_mode && thd->lex->requires_prelocking();
+#ifdef HAVE_ROW_BASED_REPLICATION
thd->binlog_flush_pending_rows_event(end_stmt);
+#endif /*HAVE_ROW_BASED_REPLICATION*/
pthread_mutex_lock(&LOCK_log);
@@ -2866,8 +2874,10 @@ bool MYSQL_LOG::write(Log_event *event_info)
*/
if (opt_using_transactions && thd)
{
+#ifdef HAVE_ROW_BASED_REPLICATION
if (thd->binlog_setup_trx_data())
goto err;
+#endif /*HAVE_ROW_BASED_REPLICATION*/
binlog_trx_data *const trx_data=
(binlog_trx_data*) thd->ha_data[binlog_hton.slot];