Signal 6
Consider the process chain program (Program 2.12, pp. 69, Robbins/Robbins).
Which process will get an interactive attention signal (SIGINT) if
user types in a cntl-c on keyboard?
(Hint: Install a handler for SIGINT in the program. The handler should print
out the pid for the process receiving the signal. Test the new program
a few times to note the process receiving the signal.)
How can one insure that a specific process (e.g. first process) gets it?
Consider the problem of "orphan" processes left behind by the program
particularly for last part of Exercise 2.12. How can one add kill() call
to terminate all processes in chain before the first process exits.