summaryrefslogtreecommitdiff
path: root/sql/log.cc
diff options
context:
space:
mode:
authorunknown <serg@serg.mylan>2005-02-21 11:51:50 +0100
committerunknown <serg@serg.mylan>2005-02-21 11:51:50 +0100
commit2d044701a9a3f55db41619bcda4965102ade5f33 (patch)
treead60c2df71efa3972b33f29609baf9490fee53ef /sql/log.cc
parenta0a20345b9869731cac43438ed5c23709aa6fc14 (diff)
downloadmariadb-git-2d044701a9a3f55db41619bcda4965102ade5f33.tar.gz
xa assert fixes
sql/handler.cc: more DBUG sql/handler.h: increase MAX_HA (ha_archive has its handlerton too) sql/log.cc: fix assert
Diffstat (limited to 'sql/log.cc')
-rw-r--r--sql/log.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/sql/log.cc b/sql/log.cc
index b048323aa76..64c2a890969 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -129,11 +129,12 @@ static int binlog_rollback(THD *thd, bool all)
IO_CACHE *trans_log= (IO_CACHE*)thd->ha_data[binlog_hton.slot];
DBUG_ENTER("binlog_rollback");
/*
- first two conditions here are guaranteed - see trans_register_ha()
- call below. The third one must be true. If it is not, we're registering
+ First assert is guaranteed - see trans_register_ha() call below.
+ The second must be true. If it is not, we're registering
unnecessary, doing extra work. The cause should be found and eliminated
*/
- DBUG_ASSERT(all && mysql_bin_log.is_open() && my_b_tell(trans_log));
+ DBUG_ASSERT(all || !(thd->options & (OPTION_NOT_AUTOCOMMIT | OPTION_BEGIN)));
+ DBUG_ASSERT(mysql_bin_log.is_open() && my_b_tell(trans_log));
/*
Update the binary log with a BEGIN/ROLLBACK block if we have
cached some queries and we updated some non-transactional