From 94e7dde8af5c9107eaee41ea139145e8a9b863f9 Mon Sep 17 00:00:00 2001 From: apio Date: Wed, 11 Dec 2024 19:56:24 +0100 Subject: [PATCH] kernel/waitpid: fix a panic-causing extraneous exclamation mark Big oof moment. Thankfully kernel panics sometimes just give you the exact source of the problem :P "-- KERNEL PANIC: Check failed at kernel/src/sys/waitpid.cpp:67, in sys_waitpid: !target->dead() --" --- kernel/src/sys/waitpid.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/src/sys/waitpid.cpp b/kernel/src/sys/waitpid.cpp index f533768f..a5162a2f 100644 --- a/kernel/src/sys/waitpid.cpp +++ b/kernel/src/sys/waitpid.cpp @@ -64,7 +64,7 @@ Result sys_waitpid(Registers* regs, SyscallArgs args) check(current->child_being_waited_for != -1); target = TRY(Result::from_option(Scheduler::find_by_pid(current->child_being_waited_for), ESRCH)); - check(!target->dead()); + check(target->dead()); } else target = child.value();