jdp@killer.DALLAS.TX.US (Jim Pritchett) (11/16/88)
How can I clear a break (i.e. ctrl-C, D, E, and F) from within my Aztec C program? (Sometimes, a left-over break [i.e. CLI bug] is passed to a program on startup. I would like to clear this signal before my program is instantly killed.) Also, why are some of the signal definitions commented out in the Manx signals.h file? Thank you, Jim Pritchett killer!gtmvax!dms3b1!caleb!jdp
dillon@POSTGRES.BERKELEY.EDU (Matt Dillon) (11/16/88)
>How can I clear a break (i.e. ctrl-C, D, E, and F) from within my Aztec C >program? (Sometimes, a left-over break [i.e. CLI bug] is passed to a program >on startup. I would like to clear this signal before my program is instantly >killed.) Look in libraries/dos.h, the signal bits are 12, 13, 14, and 15 : SIGBREAKF_CTRL_C SIGBREAKF_CTRL_D SIGBREAKF_CTRL_E SIGBREAKF_CTRL_F The SetSignal() call may be used to clear/check the signals. The call takes two arguments, a signal-set and a signal-mask. To clear the four signals: #define SIGS (SIGBREAKF_CTRL_C|SIGBREAKF_CTRL_D|SIGBREAKF_CTRL_E|\ SIGBREAKF_CTRL_F) SetSignal(0L, SIGS); The current state of all EXEC signals may be read without clearing them with long State = SetSignal(0L, 0L); >Also, why are some of the signal definitions commented out in the Manx >signals.h file? > Jim Pritchett This has nothing to do with EXEC signals, but some internal scheme of Aztec's to try to mimic the UNIX signal mechanism. The commented out #defines are probably not implemented yet. -Matt