mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 20:29:18 +00:00
Kernel: Make process list a singleton
This commit is contained in:
parent
626b99ce1c
commit
8554b66d09
Notes:
sideshowbarker
2024-07-18 07:20:03 +09:00
Author: https://github.com/boricj
Commit: 8554b66d09
Pull-request: https://github.com/SerenityOS/serenity/pull/8851
Reviewed-by: https://github.com/awesomekling ✅
Reviewed-by: https://github.com/bgianfo
3 changed files with 22 additions and 18 deletions
|
@ -66,7 +66,7 @@ KResult Process::do_killall(int signal)
|
|||
|
||||
// Send the signal to all processes we have access to for.
|
||||
ScopedSpinLock lock(g_processes_lock);
|
||||
for (auto& process : *g_processes) {
|
||||
for (auto& process : processes()) {
|
||||
KResult res = KSuccess;
|
||||
if (process.pid() == pid())
|
||||
res = do_killself(signal);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue