Consistently use SIGNAL_HANDLER() macro to define signal handler functions

With this change, the signal handler signature is defined in only one place.

Also make most signal handler functions static (those that are only referred to in irc.c).
This commit is contained in:
Kevin Easton
2017-08-22 22:48:06 +10:00
parent 742eeb33f7
commit 05633c9bc3
4 changed files with 13 additions and 16 deletions

View File

@@ -160,12 +160,12 @@ typedef int socklen_t;
#include <limits.h>
typedef RETSIGTYPE sigfunc (int);
sigfunc *my_signal (int, sigfunc *, int);
#define SIGNAL_HANDLER(x) \
RETSIGTYPE x (int unused)
typedef SIGNAL_HANDLER(sigfunc);
sigfunc *my_signal (int, sigfunc *, int);
#include <stdlib.h>
#define index strchr