diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2021-07-23 17:29:51 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2021-07-23 17:29:51 +0300 |
commit | 42b9daaea7ece6155558f7c3bf638e8e175a7ff7 (patch) | |
tree | d11ac5ab67eb044318ab6d2afc2084de4bb7153b | |
parent | c35ac5489176713e3d7137789afc1c328980822b (diff) | |
download | mariadb-git-42b9daaea7ece6155558f7c3bf638e8e175a7ff7.tar.gz |
MDEV-26138 innodb_flush_log_at_trx_commit=3 doesn't flush
trx_flush_log_if_needed_low(): Do flush for both
innodb_flush_log_at_trx_commit=1 and
innodb_flush_log_at_trx_commit=3.
This is the 10.6 version of
10.2 commit 5f8651ac238d8d6cd3e4a7e3090b4b529f990331
which fixed a regression that had been introduced
in 2e814d4702d71a04388386a9f591d14a35980bfe
(breaking 288eeb3a31e4bfb52180f3906a4d354ac9cc457e).
-rw-r--r-- | storage/innobase/trx/trx0trx.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/storage/innobase/trx/trx0trx.cc b/storage/innobase/trx/trx0trx.cc index 3763ed67c98..18c1eea3ab5 100644 --- a/storage/innobase/trx/trx0trx.cc +++ b/storage/innobase/trx/trx0trx.cc @@ -1135,8 +1135,8 @@ static void trx_flush_log_if_needed_low(lsn_t lsn, trx_state_t trx_state) if (log_sys.get_flushed_lsn() > lsn) return; - bool flush= srv_file_flush_method != SRV_NOSYNC && - srv_flush_log_at_trx_commit == 1; + const bool flush= srv_file_flush_method != SRV_NOSYNC && + (srv_flush_log_at_trx_commit & 1); if (trx_state == TRX_STATE_PREPARED) { |