1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:58:12 +00:00

Kernel: Stop sending SIGCHLD to kernel parent processes

Kernel processes cannot handle signals.
This commit is contained in:
Idan Horowitz 2022-02-21 19:47:52 +02:00 committed by Andreas Kling
parent 5a770f2eff
commit 2c996cbbee

View file

@ -606,7 +606,7 @@ void Process::finalize()
{
// FIXME: PID/TID BUG
if (auto parent_thread = Thread::from_tid(ppid().value())) {
if ((parent_thread->m_signal_action_data[SIGCHLD].flags & SA_NOCLDWAIT) != SA_NOCLDWAIT)
if (parent_thread->process().is_user_process() && (parent_thread->m_signal_action_data[SIGCHLD].flags & SA_NOCLDWAIT) != SA_NOCLDWAIT)
parent_thread->send_signal(SIGCHLD, this);
}
}