diff options
author | jimw@mysql.com <> | 2005-12-09 15:00:33 -0800 |
---|---|---|
committer | jimw@mysql.com <> | 2005-12-09 15:00:33 -0800 |
commit | d07a57c03ae13cbbf7fe68cd4eebc8b7266eaa69 (patch) | |
tree | 8e54fb8c42c750aceab7ac826bb3f35b4eabadeb /sql/handler.cc | |
parent | a4cc61f21351303e903a6511baa94990cec96380 (diff) | |
download | mariadb-git-d07a57c03ae13cbbf7fe68cd4eebc8b7266eaa69.tar.gz |
Fix crash in BDB from improper cleanup of transactions, and avoid problem
in NDB that the fix would cause due to improper registration of a transaction
that isn't meant to be seen by the handler layer. (Bug #14212)
Thanks to Sergei Golubchik for helping with this.
Diffstat (limited to 'sql/handler.cc')
-rw-r--r-- | sql/handler.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/handler.cc b/sql/handler.cc index 81e94af5dc7..416455c9bb9 100644 --- a/sql/handler.cc +++ b/sql/handler.cc @@ -1910,7 +1910,8 @@ int ha_enable_transaction(THD *thd, bool on) is an optimization hint that storage engine is free to ignore. So, let's commit an open transaction (if any) now. */ - error= end_trans(thd, COMMIT); + if (!(error= ha_commit_stmt(thd))) + error= end_trans(thd, COMMIT); } DBUG_RETURN(error); } |