From 6ddf8f34dbc5763be82061453e6a0719ea4aa247 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sat, 6 Oct 2018 01:11:56 -0400 Subject: kernel/mutex: Amend behavior of TransferMutexOwnership() This was the result of a typo accidentally introduced in e51d715700a35a8f14e5b804b6f7553c9a40888b. This restores the previous correct behavior. The behavior with the reference was incorrect and would cause some games to fail to boot. --- src/core/hle/kernel/mutex.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core/hle/kernel') diff --git a/src/core/hle/kernel/mutex.cpp b/src/core/hle/kernel/mutex.cpp index 78d8b74bb..dd541ffcc 100644 --- a/src/core/hle/kernel/mutex.cpp +++ b/src/core/hle/kernel/mutex.cpp @@ -47,7 +47,7 @@ static std::pair, u32> GetHighestPriorityMutexWaitingThread( /// Update the mutex owner field of all threads waiting on the mutex to point to the new owner. static void TransferMutexOwnership(VAddr mutex_addr, SharedPtr current_thread, SharedPtr new_owner) { - const auto& threads = current_thread->GetMutexWaitingThreads(); + const auto threads = current_thread->GetMutexWaitingThreads(); for (const auto& thread : threads) { if (thread->GetMutexWaitAddress() != mutex_addr) continue; -- cgit v1.2.3