|
|
发表于 2006-2-16 12:58:52
|
显示全部楼层
from man sigaction
POSIX.1-1990 disallowed setting the action for SIGCHLD to SIG_IGN. POSIX.1-2001 allows this pos-
sibility, so that ignoring SIGCHLD can be used to prevent the creation of zombies (see wait(2)).
Nevertheless, the historical BSD and System V behaviours for ignoring SIGCHLD differ, so that the
only completely portable method of ensuring that terminated children do not become zombies is to
catch the SIGCHLD signal and perform a wait(2) or similar. |
|