1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-20 21:08:08 +01:00

Remove #ifdef SYS_SIGLIST_DECLARED constructs

SYS_SIGLIST_DECLARED was defined nowhere and it was
clearly some dead code.
This commit is contained in:
Carlos R. Mafra
2009-10-17 01:05:28 +02:00
parent 1f1eb393f8
commit 96b9b22cb2
2 changed files with 0 additions and 32 deletions

View File

@@ -1954,11 +1954,7 @@ int wShowCrashingDialogPanel(int whatSig)
WMResizeWidget(panel->noteL, PWIDTH - 20, 40); WMResizeWidget(panel->noteL, PWIDTH - 20, 40);
WMMoveWidget(panel->noteL, 10, 90); WMMoveWidget(panel->noteL, 10, 90);
WMSetLabelTextAlignment(panel->noteL, WAJustified); WMSetLabelTextAlignment(panel->noteL, WAJustified);
#ifdef SYS_SIGLIST_DECLARED
snprintf(buf, sizeof(buf), _("Window Maker received signal %i\n(%s)."), whatSig, sys_siglist[whatSig]);
#else
snprintf(buf, sizeof(buf), _("Window Maker received signal %i."), whatSig); snprintf(buf, sizeof(buf), _("Window Maker received signal %i."), whatSig);
#endif
WMSetLabelText(panel->noteL, buf); WMSetLabelText(panel->noteL, buf);
panel->note2L = WMCreateLabel(panel->win); panel->note2L = WMCreateLabel(panel->win);

View File

@@ -66,12 +66,6 @@
#include "xutil.h" #include "xutil.h"
#if 0
#ifdef SYS_SIGLIST_DECLARED
extern const char *const sys_siglist[];
#endif
#endif
/* for SunOS */ /* for SunOS */
#ifndef SA_RESTART #ifndef SA_RESTART
# define SA_RESTART 0 # define SA_RESTART 0
@@ -240,32 +234,14 @@ static RETSIGTYPE handleExitSig(int sig)
sigprocmask(SIG_BLOCK, &sigs, NULL); sigprocmask(SIG_BLOCK, &sigs, NULL);
if (sig == SIGUSR1) { if (sig == SIGUSR1) {
#ifdef SYS_SIGLIST_DECLARED
wwarning("got signal %i (%s) - restarting\n", sig, sys_siglist[sig]);
#else
wwarning("got signal %i - restarting\n", sig); wwarning("got signal %i - restarting\n", sig);
#endif
SIG_WCHANGE_STATE(WSTATE_NEED_RESTART); SIG_WCHANGE_STATE(WSTATE_NEED_RESTART);
} else if (sig == SIGUSR2) { } else if (sig == SIGUSR2) {
#ifdef SYS_SIGLIST_DECLARED
wwarning("got signal %i (%s) - rereading defaults\n", sig, sys_siglist[sig]);
#else
wwarning("got signal %i - rereading defaults\n", sig); wwarning("got signal %i - rereading defaults\n", sig);
#endif
SIG_WCHANGE_STATE(WSTATE_NEED_REREAD); SIG_WCHANGE_STATE(WSTATE_NEED_REREAD);
} else if (sig == SIGTERM || sig == SIGINT || sig == SIGHUP) { } else if (sig == SIGTERM || sig == SIGINT || sig == SIGHUP) {
#ifdef SYS_SIGLIST_DECLARED
wwarning("got signal %i (%s) - exiting...\n", sig, sys_siglist[sig]);
#else
wwarning("got signal %i - exiting...\n", sig); wwarning("got signal %i - exiting...\n", sig);
#endif
SIG_WCHANGE_STATE(WSTATE_NEED_EXIT); SIG_WCHANGE_STATE(WSTATE_NEED_EXIT);
} }
sigprocmask(SIG_UNBLOCK, &sigs, NULL); sigprocmask(SIG_UNBLOCK, &sigs, NULL);
@@ -285,11 +261,7 @@ static void dummyHandler(int sig)
*/ */
static RETSIGTYPE handleSig(int sig) static RETSIGTYPE handleSig(int sig)
{ {
#ifdef SYS_SIGLIST_DECLARED
wfatal("got signal %i (%s)\n", sig, sys_siglist[sig]);
#else
wfatal("got signal %i\n", sig); wfatal("got signal %i\n", sig);
#endif
/* Setting the signal behaviour back to default and then reraising the /* Setting the signal behaviour back to default and then reraising the
* signal is a cleaner way to make program exit and core dump than calling * signal is a cleaner way to make program exit and core dump than calling