summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Lioncash2019-03-14 21:51:03 -0400
committerGravatar Lioncash2019-03-15 23:02:10 -0400
commite0d1f119680e9fa842ade586106bcc6740930583 (patch)
tree5cd5d3335fbeb75e730ba82931cc5d7c11815f10
parentkernel/thread: Amend condition within UpdatePriority() (diff)
downloadyuzu-e0d1f119680e9fa842ade586106bcc6740930583.tar.gz
yuzu-e0d1f119680e9fa842ade586106bcc6740930583.tar.xz
yuzu-e0d1f119680e9fa842ade586106bcc6740930583.zip
kernel/thread: Make bracing consistent within UpdatePriority()
Diffstat (limited to '')
-rw-r--r--src/core/hle/kernel/thread.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/core/hle/kernel/thread.cpp b/src/core/hle/kernel/thread.cpp
index 4b68b555f..c5cee12dd 100644
--- a/src/core/hle/kernel/thread.cpp
+++ b/src/core/hle/kernel/thread.cpp
@@ -306,12 +306,14 @@ void Thread::UpdatePriority() {
306 // Find the highest priority among all the threads that are waiting for this thread's lock 306 // Find the highest priority among all the threads that are waiting for this thread's lock
307 u32 new_priority = nominal_priority; 307 u32 new_priority = nominal_priority;
308 if (!wait_mutex_threads.empty()) { 308 if (!wait_mutex_threads.empty()) {
309 if (wait_mutex_threads.front()->current_priority < new_priority) 309 if (wait_mutex_threads.front()->current_priority < new_priority) {
310 new_priority = wait_mutex_threads.front()->current_priority; 310 new_priority = wait_mutex_threads.front()->current_priority;
311 }
311 } 312 }
312 313
313 if (new_priority == current_priority) 314 if (new_priority == current_priority) {
314 return; 315 return;
316 }
315 317
316 scheduler->SetThreadPriority(this, new_priority); 318 scheduler->SetThreadPriority(this, new_priority);
317 current_priority = new_priority; 319 current_priority = new_priority;