From 8f36c8f0ad162a55b5b7cc503fb153327d385729 Mon Sep 17 00:00:00 2001 From: lizzie Date: Sun, 24 May 2026 02:46:33 +0000 Subject: [PATCH] tststs --- src/common/thread.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/common/thread.cpp b/src/common/thread.cpp index 2cf5cdf14e..e8cde09ddb 100644 --- a/src/common/thread.cpp +++ b/src/common/thread.cpp @@ -233,11 +233,8 @@ bool Event::WaitFor(const std::chrono::nanoseconds time) { bool Event::WaitFor(const std::chrono::nanoseconds time) { #ifdef _WIN32 auto const end = Common::g_wall_clock.GetTimeNS() + time; - while (!is_set.load() && rem > 0) { + while (!is_set.load() && end > Common::g_wall_clock.GetTimeNS()) Common::Windows::SleepForOneTick(); - if (Common::g_wall_clock.GetTimeNS() > end) - break; - } if (is_set.load()) Reset(); return true;