diff options
author | Jeff Johnston <jjohnstn@redhat.com> | 2002-07-24 18:18:07 +0000 |
---|---|---|
committer | Jeff Johnston <jjohnstn@redhat.com> | 2002-07-24 18:18:07 +0000 |
commit | 9cef8ef52b51ec39d9d38ec206824ae81e12edfa (patch) | |
tree | 66f789f774887ea50cdf3c2ec59304d932665f96 /newlib/libc/include/sys/signal.h | |
parent | a703e0f2ee6fd5c100b6a2071bef61a0c31c2504 (diff) | |
download | cygnal-9cef8ef52b51ec39d9d38ec206824ae81e12edfa.tar.gz cygnal-9cef8ef52b51ec39d9d38ec206824ae81e12edfa.tar.bz2 cygnal-9cef8ef52b51ec39d9d38ec206824ae81e12edfa.zip |
2002-07-24 Jeff Johnston <jjohnstn@redhat.com>
* libc/include/signal.h (SIG_IGN, SIG_DFL, SIG_ERR): Change
to use _sig_func_ptr type casted constants.
(_sig_func_ptr): Typedef moved to sys/signal.h.
* libc/include/sys/signal.h (_sig_func_ptr): Typedef added.
For __rtems, use POSIX definition, otherwise default to ANSI.
* libc/sys/linux/sys/signal.h (_sig_func_ptr): Typedef added.
Diffstat (limited to 'newlib/libc/include/sys/signal.h')
-rw-r--r-- | newlib/libc/include/sys/signal.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/newlib/libc/include/sys/signal.h b/newlib/libc/include/sys/signal.h index 11d370ac4..dde3aaa04 100644 --- a/newlib/libc/include/sys/signal.h +++ b/newlib/libc/include/sys/signal.h @@ -84,13 +84,15 @@ typedef struct { * application should not use both simultaneously. */ +typedef void (*_sig_func_ptr)(); + struct sigaction { int sa_flags; /* Special flags to affect behavior of signal */ sigset_t sa_mask; /* Additional set of signals to be blocked */ /* during execution of signal-catching */ /* function. */ union { - void (*_handler)(); /* SIG_DFL, SIG_IGN, or pointer to a function */ + _sig_func_ptr _handler; /* SIG_DFL, SIG_IGN, or pointer to a function */ #if defined(_POSIX_REALTIME_SIGNALS) void (*_sigaction)( int, siginfo_t *, void * ); #endif @@ -104,9 +106,11 @@ struct sigaction { #else +typedef void (*_sig_func_ptr)(int); + struct sigaction { - void (*sa_handler)(int); + _sig_func_ptr sa_handler; sigset_t sa_mask; int sa_flags; }; |