From 5729ac0fc685d42035dfa1c850672822a247851c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9o=20Lam?= Date: Fri, 21 Jul 2017 16:04:02 +0800 Subject: [PATCH] Core: Replace recursive locking from PauseAndLock PauseAndLock cannot be called recursively anymore. --- Source/Core/Core/Core.cpp | 6 ------ 1 file changed, 6 deletions(-) diff --git a/Source/Core/Core/Core.cpp b/Source/Core/Core/Core.cpp index fefe7d7888..31cb2d8b4c 100644 --- a/Source/Core/Core/Core.cpp +++ b/Source/Core/Core/Core.cpp @@ -102,7 +102,6 @@ static StoppedCallbackFunc s_on_stopped_callback; static std::thread s_cpu_thread; static bool s_request_refresh_info = false; -static int s_pause_and_lock_depth = 0; static bool s_is_throttler_temp_disabled = false; struct HostJob @@ -765,11 +764,6 @@ static bool PauseAndLock(bool do_lock, bool unpause_on_unlock) if (!IsRunning()) return true; - // let's support recursive locking to simplify things on the caller's side, - // and let's do it at this outer level in case the individual systems don't support it. - if (do_lock ? s_pause_and_lock_depth++ : --s_pause_and_lock_depth) - return true; - bool was_unpaused = true; if (do_lock) {