Bin Chen wrote: > A little update for this problem, I wrote a propram to test the CTRL-C > signal, I found if I call: > > signal(SIGINT, handler); > > in main(), then the program can get the SIGINT when I press CTRL-C, but > if I comment out this line, the SIGINT can't cause the program exit. > > I think this is caused by the default SIGINT processing logic inherited > from the busybox shell, right? In older busybox version we didn't > encounter this before, so maybe the reason is the default processing > logic for SIGINT in older busybox shell is exit. > > Will a program started from shell inherit the signal processing > properties from the shell? >
That explains it. I have a busybox 1.00 system that has been annoying me with this behavior. The setting of SIG_DFL/SIG_IGN and the signal mask are inherited by child processes. If telnetd masked SIGINT or set it to SIG_IGN that might keep the child processes from receiving the SIGINT. David Daney. _______________________________________________ busybox mailing list [email protected] http://busybox.net/cgi-bin/mailman/listinfo/busybox
