瀏覽代碼

Merge pull request #794 from lioncash/ref

mutex: Pass SharedPtr to GetHighestPriorityMutexWaitingThread() by reference
bunnei 8 年之前
父節點
當前提交
d092ea0870
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/core/hle/kernel/mutex.cpp

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

@@ -19,7 +19,7 @@ namespace Kernel {
 /// Returns the number of threads that are waiting for a mutex, and the highest priority one among
 /// those.
 static std::pair<SharedPtr<Thread>, u32> GetHighestPriorityMutexWaitingThread(
-    SharedPtr<Thread> current_thread, VAddr mutex_addr) {
+    const SharedPtr<Thread>& current_thread, VAddr mutex_addr) {
 
     SharedPtr<Thread> highest_priority_thread;
     u32 num_waiters = 0;