[PATCH app-xcalc] Replace signal_t with void

Gaetan Nadon memsize at videotron.ca
Tue Dec 17 08:33:17 PST 2013


Now that Imake SIGNALRETURNSINT has been removed, the signal handler
function return type can only be void.

Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
---
 math.c  |    4 ++--
 xcalc.h |    7 ++-----
 2 files changed, 4 insertions(+), 7 deletions(-)

diff --git a/math.c b/math.c
index abd189f..aff9c6e 100644
--- a/math.c
+++ b/math.c
@@ -144,7 +144,7 @@ void fail_op(void)
 }
 
 /*ARGSUSED*/
-signal_t fperr(int sig)
+void fperr(int sig)
 {
 #if defined(SYSV) || defined(SVR4) || defined(linux)
     signal(SIGFPE, fperr);
@@ -155,7 +155,7 @@ signal_t fperr(int sig)
 
 /* for VAX BSD4.3 */
 /*ARGSUSED*/
-signal_t illerr(int sig)
+void illerr(int sig)
 {
     /* not reset when caught? */
     signal(SIGILL, illerr);
diff --git a/xcalc.h b/xcalc.h
index ad0f317..1492a01 100644
--- a/xcalc.h
+++ b/xcalc.h
@@ -55,9 +55,6 @@ from the X Consortium.
 #include <errno.h>
 #include <X11/Xlocale.h>
 
-
-#define signal_t void
-
 #define kRECIP 0	/* reciprocal */
 #define kSQR   1	/* square */
 #define kSQRT  2	/* square root */
@@ -118,8 +115,8 @@ extern XtActionsRec Actions[];
 extern int ActionsCount;
 
 /* math.c */
-extern signal_t fperr(int sig) _X_NORETURN;
-extern signal_t illerr(int sig) _X_NORETURN;
+extern void fperr(int sig) _X_NORETURN;
+extern void illerr(int sig) _X_NORETURN;
 extern void fail_op(void);
 extern int pre_op(int keynum);
 extern void post_op(void);
-- 
1.7.9.5



More information about the xorg-devel mailing list