diff --git a/x11/configure.ac b/x11/configure.ac index 9e4d60ad..f6e42dc1 100644 --- a/x11/configure.ac +++ b/x11/configure.ac @@ -152,10 +152,6 @@ MH_SHARED_LIBRARY(XCurses) AC_CONFIG_FILES([Makefile xcurses-config]) AC_OUTPUT -AC_DEFINE([PDC_MAX_SIGNALS], [], - [Define as the system defined limit for number of signals] -) - AC_DEFINE([HAVE_DECKEYSYM_H], [], [Define if you have the header file] ) diff --git a/x11/pdcx11.h b/x11/pdcx11.h index 70abab8b..76bef899 100644 --- a/x11/pdcx11.h +++ b/x11/pdcx11.h @@ -10,7 +10,6 @@ # include #endif -#include #include #include diff --git a/x11/x11.c b/x11/x11.c index 5b08162c..2a4c0611 100644 --- a/x11/x11.c +++ b/x11/x11.c @@ -399,35 +399,6 @@ static Atom XA_UTF8_STRING(Display *dpy) } #endif -signal_handler XCursesSetSignal(int signo, signal_handler action) -{ -#if defined(SA_INTERRUPT) || defined(SA_RESTART) - struct sigaction sigact, osigact; - - sigact.sa_handler = action; - - sigact.sa_flags = -# ifdef SA_INTERRUPT -# ifdef SA_RESTART - SA_INTERRUPT | SA_RESTART; -# else - SA_INTERRUPT; -# endif -# else /* must be SA_RESTART */ - SA_RESTART; -# endif - sigemptyset(&sigact.sa_mask); - - if (sigaction(signo, &sigact, &osigact)) - return SIG_ERR; - - return osigact.sa_handler; - -#else /* not SA_INTERRUPT or SA_RESTART, use plain signal */ - return signal(signo, action); -#endif -} - /* Convert character positions x and y to pixel positions, stored in xpos and ypos */ @@ -1732,43 +1703,6 @@ static void _handle_structure_notify(Widget w, XtPointer client_data, } } -static void _handle_signals(int signo) -{ - PDC_LOG(("%s:_handle_signals() - called: %d\n", XCLOGMSG, signo)); - - /* Patch by: Georg Fuchs */ - - XCursesSetSignal(signo, _handle_signals); - -#ifdef SIGTSTP - if (signo == SIGTSTP) - { - pause(); - return; - } -#endif -#ifdef SIGCONT - if (signo == SIGCONT) - return; -#endif -#ifdef SIGCLD - if (signo == SIGCLD) - return; -#endif -#ifdef SIGTTIN - if (signo == SIGTTIN) - return; -#endif -#ifdef SIGWINCH - if (signo == SIGWINCH) - return; -#endif - - /* End of patch by: Georg Fuchs */ - - XCursesSetSignal(signo, SIG_IGN); -} - static void _dummy_handler(Widget w, XtPointer client_data, XEvent *event, Boolean *unused) { @@ -1795,13 +1729,6 @@ int XCursesSetupX(int argc, char *argv[]) program_name = argv[0]; - /* Trap all signals, but only if they haven't already been ignored - by the application. */ - - for (i = 0; i < PDC_MAX_SIGNALS; i++) - if (XCursesSetSignal(i, _handle_signals) == SIG_IGN) - XCursesSetSignal(i, SIG_IGN); - /* Start defining X Toolkit things */ #if XtSpecificationRelease > 4