summaryrefslogtreecommitdiff
path: root/sql/ha_ndbcluster_binlog.cc
diff options
context:
space:
mode:
authorkostja@dipika.(none) <>2008-02-19 14:43:01 +0300
committerkostja@dipika.(none) <>2008-02-19 14:43:01 +0300
commitacf9b1f346e8b9dc59ad8e1f6a1ff20ef96d0dcd (patch)
treee540052e63f7376b653b6418116db3340c22b891 /sql/ha_ndbcluster_binlog.cc
parent48d326612aa16f2d7fdcc9e78f5f7b99f0e3c0a7 (diff)
downloadmariadb-git-acf9b1f346e8b9dc59ad8e1f6a1ff20ef96d0dcd.tar.gz
A fix and a test case for Bug#12713 "Error in a stored function called from
a SELECT doesn't cause ROLLBACK of statem". The idea of the fix is to ensure that we always commit the current statement at the end of dispatch_command(). In order to not issue redundant disc syncs, an optimization of the two-phase commit protocol is implemented to bypass the two phase commit if the transaction is read-only.
Diffstat (limited to 'sql/ha_ndbcluster_binlog.cc')
-rw-r--r--sql/ha_ndbcluster_binlog.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/sql/ha_ndbcluster_binlog.cc b/sql/ha_ndbcluster_binlog.cc
index 07b0d907229..f5fda16b391 100644
--- a/sql/ha_ndbcluster_binlog.cc
+++ b/sql/ha_ndbcluster_binlog.cc
@@ -283,6 +283,7 @@ static void run_query(THD *thd, char *buf, char *end,
thd_ndb->m_error_code,
(int) thd->is_error(), thd->is_slave_error);
}
+ close_thread_tables(thd);
/*
XXX: this code is broken. mysql_parse()/mysql_reset_thd_for_next_command()
can not be called from within a statement, and