# HG changeset patch # User Richard M. Stallman # Date 758639049 0 # Node ID f97415a8cf4108cb8522339585d3906533529cea # Parent 58c0f2c7dfae09be89232efe72ec41448905029b (request_sigio, unrequest_sigio): Add new versions of these routines for the CX/UX operating system. (sys_signal) [SA_RESTART]: Set this flag. diff -r 58c0f2c7dfae -r f97415a8cf41 src/sysdep.c --- a/src/sysdep.c Sat Jan 15 13:02:16 1994 +0000 +++ b/src/sysdep.c Sat Jan 15 13:04:09 1994 +0000 @@ -791,6 +791,32 @@ #else /* not FASYNC, not STRIDE */ +#ifdef _CX_UX + +#include + +request_sigio () +{ + int on = 1; + sigset_t st; + + sigemptyset(&st); + sigaddset(&st, SIGIO); + ioctl (input_fd, FIOASYNC, &on); + interrupts_deferred = 0; + sigprocmask(SIG_UNBLOCK, &st, (sigset_t *)0); +} + +unrequest_sigio () +{ + int off = 0; + + ioctl (input_fd, FIOASYNC, &off); + interrupts_deferred = 1; +} + +#else /* ! _CX_UX */ + request_sigio () { croak ("request_sigio"); @@ -801,6 +827,7 @@ croak ("unrequest_sigio"); } +#endif /* _CX_UX */ #endif /* STRIDE */ #endif /* FASYNC */ #endif /* F_SETFL */ @@ -2337,7 +2364,14 @@ #else sigemptyset (&new_action.sa_mask); new_action.sa_handler = action; +#ifdef SA_RESTART + /* Emacs mostly works better with restartable system services. If this + * flag exists, we probably want to turn it on here. + */ + new_action.sa_flags = SA_RESTART; +#else new_action.sa_flags = 0; +#endif sigaction (signal_number, &new_action, &old_action); return (old_action.sa_handler); #endif /* DGUX */