Skip to content

Commit 0332acc

Browse files
sjaakolaJan Lindström
authored andcommitted
MW-394
Merged fix for LOAD DATA splitting with log_bin==OFF, from mysql-wsrep-bugs/MW-394
1 parent 86d31ce commit 0332acc

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

sql/sql_class.cc

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4297,14 +4297,16 @@ extern "C" int thd_non_transactional_update(const MYSQL_THD thd)
42974297
extern "C" int thd_binlog_format(const MYSQL_THD thd)
42984298
{
42994299
#ifdef WITH_WSREP
4300-
if (((WSREP(thd) && wsrep_emulate_bin_log) || mysql_bin_log.is_open()) &&
4301-
(thd->variables.option_bits & OPTION_BIN_LOG))
4302-
#else
4300+
if (WSREP(thd))
4301+
{
4302+
/* for wsrep binlog format is meaningful also when binlogging is off */
4303+
return (int) WSREP_BINLOG_FORMAT(thd->variables.binlog_format);
4304+
}
4305+
#endif /* WITH_WSREP */
43034306
if (mysql_bin_log.is_open() && (thd->variables.option_bits & OPTION_BIN_LOG))
4304-
#endif
4305-
return (int) WSREP_BINLOG_FORMAT(thd->variables.binlog_format);
4307+
return (int) thd->variables.binlog_format;
43064308
else
4307-
return BINLOG_FORMAT_UNSPEC;
4309+
return BINLOG_FORMAT_UNSPEC;
43084310
}
43094311

43104312
extern "C" void thd_mark_transaction_to_rollback(MYSQL_THD thd, bool all)

0 commit comments

Comments
 (0)