Turning off the CTRL-C handler

From: Sarah Officer <officers_at_nemesis.tucson.saic.com>
Date: Fri, 7 Apr 1995 10:22:49 -0700 (MST)

Is there a simple way to turn off the SIGINT handler for STk from

I have a C application that forks a process and redirect's it's standard
input. The forked process executes an STk application. Data is piped to it
from the parent process.

The problem I have is when the user hits control-C. The parent process
traps this and offers the user some options, but the STk (forked process)
also catches the control C and opens up the TK window with the
"Error: Control-C interrupt" message. Eventually the parent process will
either kill the child process or continue. Since STk sets the SIGINT
handler when it is invoked, I can't set a different handler for the process
before invoking STk.

I tried setting the child process to a different process group, but I
had compatiblity problems on different platforms (SUN4, SOLARIS, SGI),
and if the execute of the STk application failed, it was difficult to
kill the process. Is there a clean way to prevent STk from getting
the Control-C?


Sarah Officer
Received on Fri Apr 07 1995 - 19:21:37 CEST

This archive was generated by hypermail 2.3.0 : Mon Jul 21 2014 - 19:38:59 CEST