summaryrefslogtreecommitdiff
path: root/sql/log.cc
diff options
context:
space:
mode:
Diffstat (limited to 'sql/log.cc')
-rw-r--r--sql/log.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/log.cc b/sql/log.cc
index 9f724534e6e..aa63736b796 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -7964,6 +7964,7 @@ MYSQL_BIN_LOG::trx_group_commit_leader(group_commit_entry *leader)
*/
for (current= queue; current != NULL; current= current->next)
{
+ set_current_thd(current->thd);
binlog_cache_mngr *cache_mngr= current->cache_mngr;
/*
@@ -7999,6 +8000,7 @@ MYSQL_BIN_LOG::trx_group_commit_leader(group_commit_entry *leader)
cache_mngr->delayed_error= false;
}
}
+ set_current_thd(leader->thd);
bool synced= 0;
if (unlikely(flush_and_sync(&synced)))