Commit 758af98f authored by Marko Mäkelä's avatar Marko Mäkelä

Post-push fix for Part 1 of MDEV-8139 Fix scrubbing tests

In the backport of Bug#24450908 UNDO LOG EXISTS AFTER SLOW SHUTDOWN
from MySQL 5.7 to the MySQL 5.6 based MariaDB Server 10.1, we must
use a mutex when HAVE_ATOMIC_BUILTINS is not defined.

Also, correct a function comment. In MySQL 5.6 and MariaDB Server 10.1,
also temporary InnoDB tables are redo-logged.
parent ffb38c97
......@@ -294,15 +294,19 @@ trx_purge_remove_log_hdr(
{
flst_remove(rseg_hdr + TRX_RSEG_HISTORY,
log_hdr + TRX_UNDO_HISTORY_NODE, mtr);
#ifdef HAVE_ATOMIC_BUILTINS
os_atomic_decrement_ulint(&trx_sys->rseg_history_len, 1);
#else
mutex_enter(&trx_sys->mutex);
--trx_sys->rseg_history_len;
mutex_exit(&trx_sys->mutex);
#endif
}
/** Frees an undo log segment which is in the history list. Removes the
undo log hdr from the history list.
@param[in,out] rseg rollback segment
@param[in] hdr_addr file address of log_hdr
@param[in] noredo skip redo logging. */
@param[in] hdr_addr file address of log_hdr */
static
void
trx_purge_free_segment(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment