How can an application be informed of signals?
[Last modified: Jun 98] Answer: The answer differs depending on whether you’re using X11R5 or X11R6. For those using X11R6, Ken Lee (http://www.rahul.net/kenton/) writes: In X11R6, the Xt library has the new XtAppAddSignal() function. Ken Lee’s December, 1995 *The X Advisor* column has an example: http://www.rahul.net/kenton/txa/dec95.html For those using X11R5, these older responses apply: blackman@hodgkin.med.upenn.edu (David Blackman) writes: According to comp.windows.x FAQ, you shouldn’t make Xt/Xlib calls from a Unix signal handler: “You can work around the problem by setting a flag in the interrupt handler and later checking it with a work procedure or a timer event which has previously been added.” Kaleb KEITHLEY (fedora.x.org!kaleb) adds: Xt is not reentrant and it is not safe to call any Xt functions from a signal handler… I think [the signaling] technique is covered in the [X] FAQ. On most POSIX-type systems write(2) is guaranteed to be reentrant and atomic. If you establis