mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 04:38:11 +00:00
Scheduler: Fix deadlock when first scheduling candidate being inspected
Somewhat reproducible by opening ProcessManager and trying to view the
stacks for WindowServer.
Regressed in 53262cd08b
.
This commit is contained in:
parent
38c80d5e6d
commit
09cd3a7a07
1 changed files with 1 additions and 1 deletions
|
@ -396,7 +396,7 @@ bool Scheduler::pick_next()
|
|||
auto* previous_head = runnable_list.first();
|
||||
for (;;) {
|
||||
// Move head to tail.
|
||||
runnable_list.append(*previous_head);
|
||||
runnable_list.append(*runnable_list.first());
|
||||
auto* thread = runnable_list.first();
|
||||
|
||||
if (!thread->process().is_being_inspected() && (thread->state() == Thread::Runnable || thread->state() == Thread::Running)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue