diff options
-rw-r--r-- | sql/sql_class.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc index 10bee9e7aae..b516791b6da 100644 --- a/sql/sql_class.cc +++ b/sql/sql_class.cc @@ -5230,8 +5230,9 @@ thd_need_ordering_with(const MYSQL_THD thd, const MYSQL_THD other_thd) (e.g. InnoDB does it by keeping lock_sys.mutex locked) */ if (WSREP_ON && - wsrep_thd_is_BF(const_cast<THD *>(thd), false) && - wsrep_thd_is_BF(const_cast<THD *>(other_thd), false)) + wsrep_thd_is_BF(thd, false) && + wsrep_thd_is_BF(other_thd, false) && + wsrep_thd_order_before(thd, other_thd)) return 0; #endif /* WITH_WSREP */ rgi= thd->rgi_slave; |