mirror of
https://github.com/RGBCube/serenity
synced 2025-05-28 12:05:08 +00:00
Thread: Normalize all for_each constructs to use IterationDecision
This way a caller can abort the for_each early if they want.
This commit is contained in:
parent
a5d80f7e3b
commit
e74dce65e6
3 changed files with 39 additions and 24 deletions
|
@ -178,6 +178,7 @@ void Thread::finalize_dying_threads()
|
|||
InterruptDisabler disabler;
|
||||
for_each_in_state(Thread::State::Dying, [&](Thread& thread) {
|
||||
dying_threads.append(&thread);
|
||||
return IterationDecision::Continue;
|
||||
});
|
||||
}
|
||||
for (auto* thread : dying_threads)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue