Remove preprocessor conditionals for ANSI-standard signals
The six signals SIGINT, SIGILL, SIGABRT, SIGFPE, SIGSEGV and SIGTERM are ANSI-standard and thus guaranteed to be available. This patch removes all preprocessor conditionals relating to these symbols. gdb/ 2014-06-06 Gary Benson <gbenson@redhat.com> * common/signals.c: Remove preprocessor conditionals for always-defined signals SIGINT, SIGILL, SIGABRT, SIGFPE, SIGSEGV and SIGTERM. * proc-events.c: Likewise. gdb/testsuite/ 2014-06-06 Gary Benson <gbenson@redhat.com> * gdb.base/call-signals.c: Remove preprocessor conditionals for always-defined signals SIGINT, SIGILL, SIGABRT, SIGFPE, SIGSEGV and SIGTERM. * gdb.base/sigall.c: Likewise. * gdb.base/unwindonsignal.c: Likewise. * gdb.reverse/sigall-reverse.c: Likewise.
This commit is contained in:
parent
adcc0a31cc
commit
73ba372ccf
8 changed files with 20 additions and 72 deletions
|
@ -819,11 +819,7 @@ return 0;
|
|||
int
|
||||
gen_ILL ()
|
||||
{
|
||||
#ifdef SIGILL
|
||||
kill (getpid (), SIGILL);
|
||||
#else
|
||||
handle_ILL (0);
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -874,11 +870,7 @@ return 0;
|
|||
int
|
||||
gen_SEGV ()
|
||||
{
|
||||
#ifdef SIGSEGV
|
||||
kill (getpid (), SIGSEGV);
|
||||
#else
|
||||
handle_SEGV (0);
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -1050,7 +1042,7 @@ return 0;
|
|||
int
|
||||
gen_LOST ()
|
||||
{
|
||||
#if defined(SIGLOST) && (!defined(SIGABRT) || SIGLOST != SIGABRT)
|
||||
#if defined(SIGLOST) && SIGLOST != SIGABRT
|
||||
kill (getpid (), SIGLOST);
|
||||
#else
|
||||
handle_LOST (0);
|
||||
|
@ -1593,21 +1585,15 @@ main ()
|
|||
#ifdef SIGQUIT
|
||||
signal (SIGQUIT, handle_QUIT);
|
||||
#endif
|
||||
#ifdef SIGILL
|
||||
signal (SIGILL, handle_ILL);
|
||||
#endif
|
||||
#ifdef SIGEMT
|
||||
signal (SIGEMT, handle_EMT);
|
||||
#endif
|
||||
#ifdef SIGFPE
|
||||
signal (SIGFPE, handle_FPE);
|
||||
#endif
|
||||
#ifdef SIGBUS
|
||||
signal (SIGBUS, handle_BUS);
|
||||
#endif
|
||||
#ifdef SIGSEGV
|
||||
signal (SIGSEGV, handle_SEGV);
|
||||
#endif
|
||||
#ifdef SIGSYS
|
||||
signal (SIGSYS, handle_SYS);
|
||||
#endif
|
||||
|
@ -1653,7 +1639,7 @@ main ()
|
|||
#ifdef SIGWINCH
|
||||
signal (SIGWINCH, handle_WINCH);
|
||||
#endif
|
||||
#if defined(SIGLOST) && (!defined(SIGABRT) || SIGLOST != SIGABRT)
|
||||
#if defined(SIGLOST) && SIGLOST != SIGABRT
|
||||
signal (SIGLOST, handle_LOST);
|
||||
#endif
|
||||
#ifdef SIGUSR1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue