diff options
Diffstat (limited to 'src/core/hle/kernel/thread.cpp')
| -rw-r--r-- | src/core/hle/kernel/thread.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/core/hle/kernel/thread.cpp b/src/core/hle/kernel/thread.cpp index 3ca9603c2..58523e145 100644 --- a/src/core/hle/kernel/thread.cpp +++ b/src/core/hle/kernel/thread.cpp | |||
| @@ -85,10 +85,11 @@ static void ChangeReadyState(Thread* t, bool ready) { | |||
| 85 | 85 | ||
| 86 | /// Check if a thread is waiting on a the specified wait object | 86 | /// Check if a thread is waiting on a the specified wait object |
| 87 | static bool CheckWait_WaitObject(const Thread* thread, WaitObject* wait_object) { | 87 | static bool CheckWait_WaitObject(const Thread* thread, WaitObject* wait_object) { |
| 88 | for (auto itr = thread->wait_objects.begin(); itr != thread->wait_objects.end(); ++itr) { | 88 | auto itr = std::find(thread->wait_objects.begin(), thread->wait_objects.end(), wait_object); |
| 89 | if (*itr == wait_object) | 89 | |
| 90 | return (thread->IsWaiting()); | 90 | if (itr != thread->wait_objects.end()) |
| 91 | } | 91 | return thread->IsWaiting(); |
| 92 | |||
| 92 | return false; | 93 | return false; |
| 93 | } | 94 | } |
| 94 | 95 | ||