Date: Wed, 22 May 1996 19:02:37 +0200 (IST) From: Eli Zaretskii To: Charles Sandmann Cc: djgpp AT delorie DOT com Subject: Re: Ctrl-C arg In-Reply-To: <31a1005d.sandmann@clio.rice.edu> Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Mon, 20 May 1996, Charles Sandmann wrote: > > __djgpp_set_ctrl_c(0); > > function doesn't seem to be documented anywhere: does anyone know why > > not? Is there some reason why I shouldn't be using it? > > It's an internal function which I didn't expect to be called by the users. > In the UNIX world to supress CTRL-C interrupts you would SIG_IGN SIGINT, The problem is that setting SIGINT to SIG_IGN also suppresses signals generated by Ctrl-Break. Also, if you switch stdin to binary mode, Ctrl-C stops generating SIGINT even if you don't want to ignore SIGINT. So `__djgpp_set_ctrl_c' is most useful in re-enabling SIGINT after switching stdin to binary, or selectively disabling only Ctrl-C but not Ctrl-Break. Which is why it *will* be documented in the next release of DJGPP.