summaryrefslogtreecommitdiff
path: root/include/wsrep.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/wsrep.h')
-rw-r--r--include/wsrep.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/wsrep.h b/include/wsrep.h
index a91f312d0a6..0f5455c8d50 100644
--- a/include/wsrep.h
+++ b/include/wsrep.h
@@ -31,6 +31,14 @@
if (WSREP_ON && (WSREP(thd) || (thd && thd->wsrep_exec_mode==TOTAL_ORDER))) \
wsrep_to_isolation_end(thd);
+/*
+ Checks if lex->no_write_to_binlog is set for statements that use LOCAL or
+ NO_WRITE_TO_BINLOG.
+*/
+#define WSREP_TO_ISOLATION_BEGIN_WRTCHK(db_, table_, table_list_) \
+ if (WSREP(thd) && !thd->lex->no_write_to_binlog \
+ && wsrep_to_isolation_begin(thd, db_, table_, table_list_)) goto error;
+
#define WSREP_DEBUG(...) \
if (wsrep_debug) WSREP_LOG(sql_print_information, ##__VA_ARGS__)
#define WSREP_INFO(...) WSREP_LOG(sql_print_information, ##__VA_ARGS__)
@@ -46,6 +54,7 @@
#define WSREP_ERROR(...)
#define WSREP_TO_ISOLATION_BEGIN(db_, table_, table_list_)
#define WSREP_TO_ISOLATION_END
+#define WSREP_TO_ISOLATION_BEGIN_WRTCHK(db_, table_, table_list_)
#endif
#endif /* WSERP_INCLUDED */