From ac7bf12743059a604e03a603158b9866af62c12e Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 28 Sep 2022 10:02:59 +0200 Subject: [PATCH] event/Loop: move call to FlushClockCaches() --- src/event/Loop.cxx | 4 ++-- src/event/Loop.hxx | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/event/Loop.cxx b/src/event/Loop.cxx index d7b679d4a..2674a9d5b 100644 --- a/src/event/Loop.cxx +++ b/src/event/Loop.cxx @@ -296,7 +296,7 @@ EventLoop::Run() noexcept }; #endif - steady_clock_cache.flush(); + FlushClockCaches(); do { again = false; @@ -341,7 +341,7 @@ EventLoop::Run() noexcept Wait(timeout); - steady_clock_cache.flush(); + FlushClockCaches(); #ifdef HAVE_THREADED_EVENT_LOOP { diff --git a/src/event/Loop.hxx b/src/event/Loop.hxx index 1dc75a239..7a327f1d2 100644 --- a/src/event/Loop.hxx +++ b/src/event/Loop.hxx @@ -182,6 +182,10 @@ public: return steady_clock_cache.now(); } + void FlushClockCaches() noexcept { + steady_clock_cache.flush(); + } + #ifdef HAVE_URING [[gnu::pure]] Uring::Queue *GetUring() noexcept;