summaryrefslogtreecommitdiff
path: root/sql/sql_trigger.cc
diff options
context:
space:
mode:
authorgkodinov/kgeorge@magare.gmz <>2007-06-19 14:27:53 +0300
committergkodinov/kgeorge@magare.gmz <>2007-06-19 14:27:53 +0300
commitbef15b279be6d5f2230bd27c4a39adb48a559b2b (patch)
treefc28fda969044b7b483e45355fc385e45f8554d3 /sql/sql_trigger.cc
parent16a7a45bdc4639d859e8c8257d28170c01c31148 (diff)
downloadmariadb-git-bef15b279be6d5f2230bd27c4a39adb48a559b2b.tar.gz
Bug #26418: Slave out of sync after
CREATE/DROP TEMPORARY TABLE + ROLLBACK on master The transaction ability of the storage engines of the tables on the replication master and the replication slave must generally be the same. When the storage engine type of the slave is non-transactional then transactions on the master that mix update of transactional and non-transactional tables should be avoided because they will cause inconsistency of the data between the master's transactional table and the slave's non-transactional table. The effect described by this bug is actually expected. A detailed test case is added (to be merged later to the updated rpl_ddl.test), as there was no coverage by the existing tests. Some code cleanup is also added by this change.
Diffstat (limited to 'sql/sql_trigger.cc')
-rw-r--r--sql/sql_trigger.cc9
1 files changed, 1 insertions, 8 deletions
diff --git a/sql/sql_trigger.cc b/sql/sql_trigger.cc
index e15003ab243..6e8a40e68a2 100644
--- a/sql/sql_trigger.cc
+++ b/sql/sql_trigger.cc
@@ -306,14 +306,7 @@ end:
if (!result)
{
- if (mysql_bin_log.is_open())
- {
- thd->clear_error();
-
- /* Such a statement can always go directly to binlog, no trans cache. */
- thd->binlog_query(THD::STMT_QUERY_TYPE,
- stmt_query.ptr(), stmt_query.length(), FALSE, FALSE);
- }
+ write_bin_log(thd, TRUE, stmt_query.ptr(), stmt_query.length());
}
VOID(pthread_mutex_unlock(&LOCK_open));