summaryrefslogtreecommitdiff
path: root/sql/log.cc
diff options
context:
space:
mode:
authorOleksandr Byelkin <sanja@mariadb.com>2022-02-01 20:33:04 +0100
committerOleksandr Byelkin <sanja@mariadb.com>2022-02-01 20:33:04 +0100
commitcf63eecef44f189ce2d221612dee9dfc1885ba4e (patch)
tree93b4e6645a1d371bd8012a0aa8e6e3a3d541b2a6 /sql/log.cc
parentfb40a2fabf8d8cf765c83a0b8e609dd893c75ec3 (diff)
parentc04a203a10e282e1f33fd04d8a1b7ff0b076bce5 (diff)
downloadmariadb-git-cf63eecef44f189ce2d221612dee9dfc1885ba4e.tar.gz
Merge branch '10.4' into 10.5
Diffstat (limited to 'sql/log.cc')
-rw-r--r--sql/log.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/log.cc b/sql/log.cc
index 0aec4144656..d0dcb5d3725 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -1700,7 +1700,7 @@ static int binlog_close_connection(handlerton *hton, THD *thd)
binlog_cache_mngr *const cache_mngr=
(binlog_cache_mngr*) thd_get_ha_data(thd, binlog_hton);
#ifdef WITH_WSREP
- if (cache_mngr && !cache_mngr->trx_cache.empty()) {
+ if (WSREP(thd) && cache_mngr && !cache_mngr->trx_cache.empty()) {
IO_CACHE* cache= cache_mngr->get_binlog_cache_log(true);
uchar *buf;
size_t len=0;
@@ -3706,6 +3706,7 @@ bool MYSQL_BIN_LOG::open(const char *log_name,
opt_slave_sql_verify_checksum ? (enum_binlog_checksum_alg) binlog_checksum_options
: BINLOG_CHECKSUM_ALG_OFF;
s.checksum_alg= relay_log_checksum_alg;
+ s.set_relay_log_event();
}
else
s.checksum_alg= (enum_binlog_checksum_alg)binlog_checksum_options;