VERY experimental Nintendo Switch 2 emulator
C++
nvnflinger: Acquire lock prior to signaling the vsync variable
Morphfb3bb6388064
diff --git a/src/core/hle/service/nvnflinger/nvnflinger.cpp b/src/core/hle/service/nvnflinger/nvnflinger.cppindex 4988e6e176..aa3356611f 100644--- a/src/core/hle/service/nvnflinger/nvnflinger.cpp+++ b/src/core/hle/service/nvnflinger/nvnflinger.cpp@@ -70,7 +70,8 @@ Nvnflinger::Nvnflinger(Core::System& system_, HosBinderDriverServer& hos_binder_[this](std::uintptr_t, s64 time,std::chrono::nanoseconds ns_late) -> std::optional<std::chrono::nanoseconds> {vsync_signal.store(true);- vsync_signal.notify_all();+ { const auto lock_guard = Lock(); }+ vsync_signal.notify_one();return std::chrono::nanoseconds(GetNextTicks());});