SIGCHLDの受信 #include <sys/types.h> /* ほかのsysヘッダより先にこのファイルをinlcudeする */ #include <sys/wait.h> /* waitpid()とマクロのヘッダ */ #include <signal.h> /* シグナル関数のヘッダ */ #include <stdio.h> /* fprintf()のヘッダ */ #include <unistd.h> /* fork()のヘッダ */ void sig_chld(int); /* SIGCHLDハンドラのプロトタイプ宣言 */ int main() { struct sigaction act; pid_t pid; /* sig_chldをSIGCHLDハンドラとする */ act.sa_handler = sig_chld; /* この例では、そのほかのシグナルはブ