소스 검색

Thread: Check that thread is actually in "wait state" when verifying wait.

bunnei 11 년 전
부모
커밋
de851ba1a1
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/core/hle/kernel/thread.cpp

+ 1 - 1
src/core/hle/kernel/thread.cpp

@@ -143,7 +143,7 @@ void ChangeReadyState(Thread* t, bool ready) {
 /// Verify that a thread has not been released from waiting
 inline bool VerifyWait(const Thread* thread, WaitType type, Handle wait_handle) {
     _dbg_assert_(KERNEL, thread != nullptr);
-    return type == thread->wait_type && wait_handle == thread->wait_handle;
+    return (type == thread->wait_type) && (wait_handle == thread->wait_handle) && (thread->IsWaiting());
 }
 
 /// Stops the current thread