summaryrefslogtreecommitdiff
path: root/src/core/hle/kernel/mutex.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hle/kernel/mutex.cpp')
-rw-r--r--src/core/hle/kernel/mutex.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/core/hle/kernel/mutex.cpp b/src/core/hle/kernel/mutex.cpp
index f97c69a78..4a1eaca37 100644
--- a/src/core/hle/kernel/mutex.cpp
+++ b/src/core/hle/kernel/mutex.cpp
@@ -26,7 +26,7 @@ public:
26 Handle lock_thread; ///< Handle to thread that currently has mutex 26 Handle lock_thread; ///< Handle to thread that currently has mutex
27 std::string name; ///< Name of mutex (optional) 27 std::string name; ///< Name of mutex (optional)
28 28
29 ResultVal<bool> Wait(bool wait_thread) override; 29 ResultVal<bool> Wait() override;
30 ResultVal<bool> Acquire() override; 30 ResultVal<bool> Acquire() override;
31}; 31};
32 32
@@ -156,12 +156,7 @@ Handle CreateMutex(bool initial_locked, const std::string& name) {
156 return handle; 156 return handle;
157} 157}
158 158
159ResultVal<bool> Mutex::Wait(bool wait_thread) { 159ResultVal<bool> Mutex::Wait() {
160 if (locked && wait_thread) {
161 AddWaitingThread(GetCurrentThread());
162 Kernel::WaitCurrentThread_WaitSynchronization(WAITTYPE_MUTEX, this);
163 }
164
165 return MakeResult<bool>(locked); 160 return MakeResult<bool>(locked);
166} 161}
167 162