summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/VideoConfig.cpp
diff options
context:
space:
mode:
authorJosJuice <josjuice@gmail.com>2024-04-05 22:40:24 +0200
committerJosJuice <josjuice@gmail.com>2024-04-05 22:46:48 +0200
commit9ca9d073df98b0bc976eac68c3d708fec57f3389 (patch)
tree3900da30ddf8d6cc27e18ee2d13af5bfd6ed372a /Source/Core/VideoCommon/VideoConfig.cpp
parent4312840a4b8cd52ce1beee3a13ba12afe2b59e53 (diff)
Android: Fix race condition in displayAlertMsg
It was possible for sAlertMessageLock.notify() to be called before sAlertMessageLock.wait(), causing Dolphin to deadlock. In particular, this was guaranteed to happen if displayAlertMsg was called from the UI thread while the emulation activity is being destroyed, because runOnUiThread runs the passed-in anonymous function immediately when called from the UI thread. By replacing Object.wait/Object.notify with Semaphore.acquire/ Semaphore.release, it no longer matters what order the methods are called in.
Diffstat (limited to 'Source/Core/VideoCommon/VideoConfig.cpp')
0 files changed, 0 insertions, 0 deletions