--- gforth/engine/signals.c 2003/02/02 11:05:50 1.24 +++ gforth/engine/signals.c 2003/03/08 19:52:05 1.26 @@ -72,8 +72,6 @@ void install_signal_handler(int sig, voi } #endif -typedef void Sigfunc(int); - Sigfunc *bsd_signal(int signo, Sigfunc *func) { struct sigaction act, oact; @@ -109,8 +107,19 @@ signal_throw(int sig) case SIGBUS: code=-23; break; #endif case SIGSEGV: code=-9; break; +#ifdef SIGPIPE + case SIGPIPE: code=-2049; break; +#endif default: code=-256-sig; break; } +#ifdef __CYGWIN__ + /* the SA_NODEFER apparently does not work on Cygwin 1.3.18(0.69/3/2) */ + { + sigset_t emptyset; + sigemptyset(&emptyset); + sigprocmask(SIG_SETMASK, &emptyset, NULL); + } +#endif longjmp(throw_jmp_buf,code); /* !! or use siglongjmp ? */ }