mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-08 07:05:40 +12:00
Kernel: Don't idle on svcSleepThread(0)
This commit is contained in:
parent
66847d4570
commit
60de6a65f5
1 changed files with 5 additions and 1 deletions
|
@ -348,7 +348,11 @@ void Kernel::sleepThread(s64 ns) {
|
|||
t.status = ThreadStatus::Ready;
|
||||
|
||||
if (nextThreadIndex.has_value()) {
|
||||
switchThread(nextThreadIndex.value());
|
||||
const auto index = nextThreadIndex.value();
|
||||
|
||||
if (index != idleThreadIndex) {
|
||||
switchThread(index);
|
||||
}
|
||||
}
|
||||
} else { // If we're sleeping for >= 0 ns
|
||||
Thread& t = threads[currentThreadIndex];
|
||||
|
|
Loading…
Add table
Reference in a new issue