O Que É SIGCHLD?
SIGCHLD é um signal entregue a um processo pai sempre que um filho muda de estado ao sair, ser morto ou ser parado. O pai tipicamente o trata chamando uma operação wait para fazer reap do filho e ler seu exit status. Ignorá-lo sem fazer reap deixa o filho como zombie até que o pai aja.
Por que isso importa
Supervisores de processos e shells dependem do SIGCHLD para saber quando os jobs iniciados terminam. Tratá-lo mal é uma causa comum de acúmulo de processos zombie em runners de longa duração.
Guias relacionados
What Is a Signal Handler?A signal handler is a function a program registers to run when it receives a particular signal, letting it re…
What Is the Wait System Call?The wait system call lets a parent process pause until a child terminates and then read the child exit status…
What Is Reaping a Child Process?Reaping is when a parent calls a wait operation to read a finished child exit status, freeing the kernel slot…