source: trunk/third/nmh/h/signals.h @ 12455

Revision 12455, 886 bytes checked in by danw, 26 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r12454, which included commits to RCS files with non-trunk default branches.
Line 
1
2/*
3 * signals.h -- header file for nmh signal interface
4 *
5 * $Id: signals.h,v 1.1.1.1 1999-02-07 18:14:07 danw Exp $
6 */
7
8#include <config.h>
9
10/*
11 * The type for a signal handler
12 */
13typedef RETSIGTYPE (*SIGNAL_HANDLER)(int);
14
15/*
16 * If not a POSIX machine, then we create our
17 * own POSIX style signal sets functions. This
18 * currently assumes you have 31 signals, which
19 * should be true on most pure BSD machines.
20 */
21#ifndef POSIX_SIGNALS
22# define sigemptyset(s)    (*(s) = 0)
23# define sigfillset(s)     (*(s) = ~((sigset_t) 0), 0)
24# define sigaddset(s,n)    (*(s) |=  (1 << ((n) - 1)), 0)
25# define sigdelset(s,n)    (*(s) &= ~(1 << ((n) - 1)), 0)
26# define sigismember(s,n)  ((*(s) & (1 << ((n) - 1))) != 0)
27#endif
28
29/*
30 * prototypes
31 */
32int SIGPROCMASK (int, const sigset_t *, sigset_t *);
33SIGNAL_HANDLER SIGNAL (int, SIGNAL_HANDLER);
34SIGNAL_HANDLER SIGNAL2 (int, SIGNAL_HANDLER);
Note: See TracBrowser for help on using the repository browser.