Apologies if this is a FAQ, I've searched various places for an answer without success.
Essentially: what is the signal that X-Code sends to a running process when I press the 'Terminate' button in the Run Log? Is it by any chance SIGKILL, which apparently cannot be handled by the program itself?
This is a problem for me, because I would like to cleanly shutdown some resources used by my program when terminated from the Run Log; I have handlers for SIGTERM, SIGQUIT, and these work from the shell if I use Ctrl-C ... but not from X-Code. Please note, this is a command line program with no GUI, so for the moment, Ctrl-C is how I want / expect to perform an orderly shutdown.
Anyway, if anyone could confirm X-Code's behaviour, and possibly suggest ways to modify / work around it, please do so.
Thanks, James
-- We are all in the gutter, but some of us are looking at the stars.
|