aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/include/signal.h
diff options
context:
space:
mode:
authorJeff Johnston <jjohnstn@redhat.com>2002-07-24 18:18:07 +0000
committerJeff Johnston <jjohnstn@redhat.com>2002-07-24 18:18:07 +0000
commit9cef8ef52b51ec39d9d38ec206824ae81e12edfa (patch)
tree66f789f774887ea50cdf3c2ec59304d932665f96 /newlib/libc/include/signal.h
parenta703e0f2ee6fd5c100b6a2071bef61a0c31c2504 (diff)
downloadnewlib-9cef8ef52b51ec39d9d38ec206824ae81e12edfa.zip
newlib-9cef8ef52b51ec39d9d38ec206824ae81e12edfa.tar.gz
newlib-9cef8ef52b51ec39d9d38ec206824ae81e12edfa.tar.bz2
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/signal.h')
-rw-r--r--newlib/libc/include/signal.h14
1 files changed, 3 insertions, 11 deletions
diff --git a/newlib/libc/include/signal.h b/newlib/libc/include/signal.h
index e1170a2..1b3b57b 100644
--- a/newlib/libc/include/signal.h
+++ b/newlib/libc/include/signal.h
@@ -8,17 +8,9 @@ _BEGIN_STD_C
typedef int sig_atomic_t; /* Atomic entity type (ANSI) */
-#if defined(__STDC__) || defined(__cplusplus)
-#define SIG_DFL ((void (*)(int))0) /* Default action */
-#define SIG_IGN ((void (*)(int))1) /* Ignore action */
-#define SIG_ERR ((void (*)(int))-1) /* Error return */
-#else
-#define SIG_DFL ((void (*)())0) /* Default action */
-#define SIG_IGN ((void (*)())1) /* Ignore action */
-#define SIG_ERR ((void (*)())-1) /* Error return */
-#endif
-
-typedef void (*_sig_func_ptr) (int);
+#define SIG_DFL ((_sig_func_ptr)0) /* Default action */
+#define SIG_IGN ((_sig_func_ptr)1) /* Ignore action */
+#define SIG_ERR ((_sig_func_ptr)-1) /* Error return */
struct _reent;