summaryrefslogtreecommitdiff
path: root/storage/innobase/buf/buf0flu.cc
diff options
context:
space:
mode:
Diffstat (limited to 'storage/innobase/buf/buf0flu.cc')
-rw-r--r--storage/innobase/buf/buf0flu.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/storage/innobase/buf/buf0flu.cc b/storage/innobase/buf/buf0flu.cc
index d91f036b599..32c3c816a85 100644
--- a/storage/innobase/buf/buf0flu.cc
+++ b/storage/innobase/buf/buf0flu.cc
@@ -2154,7 +2154,14 @@ page_cleaner_flush_pages_if_needed(void)
ulint pct_total = 0;
int age_factor = 0;
- cur_lsn = log_get_lsn();
+ cur_lsn = log_get_lsn_nowait();
+
+ /* log_get_lsn_nowait tries to get log_sys->mutex with
+ mutex_enter_nowait, if this does not succeed function
+ returns 0, do not use that value to update stats. */
+ if (cur_lsn == 0) {
+ return(0);
+ }
if (prev_lsn == 0) {
/* First time around. */