} while (0)
#endif
+/* Not all systems define NSIG in signal.h */
+#if !defined(NSIG)
+# if defined(_NSIG)
+# define NSIG _NSIG
+# elif defined(__NSIG)
+# define NSIG __NSIG
+# else
+# define NSIG 64
+# endif
+#endif
+
#ifndef WCOREDUMP
# define WCOREDUMP(x) ((x) & 0x80)
#endif
# include <selinux/selinux.h>
#endif
-/* XXX - move to compat */
-#if !defined(NSIG)
-# if defined(_NSIG)
-# define NSIG _NSIG
-# elif defined(__NSIG)
-# define NSIG __NSIG
-# else
-# define NSIG 64
-# endif
-#endif
-
#include "sudo.h"
/* shared with exec_pty.c */
#include <fcntl.h>
#include <signal.h>
-/* XXX - move to compat.h */
-#if !defined(NSIG)
-# if defined(_NSIG)
-# define NSIG _NSIG
-# elif defined(__NSIG)
-# define NSIG __NSIG
-# else
-# define NSIG 64
-# endif
-#endif
-
#include "sudo.h"
#define SFD_STDIN 0
#include <compat.h>
-#if !defined(NSIG)
-# if defined(_NSIG)
-# define NSIG _NSIG
-# elif defined(__NSIG)
-# define NSIG __NSIG
-# else
-# error one of NSIG, _NSIG, or __NSIG must be defined
-# endif
-#endif
-
int
main(argc, argv)
int argc;
#include <config.h>
#include <compat.h>
-#if !defined(NSIG)
-# if defined(_NSIG)
-# define NSIG _NSIG
-# elif defined(__NSIG)
-# define NSIG __NSIG
-# else
-# error one of NSIG, _NSIG, or __NSIG must be defined
-# endif
-#endif
-
#if defined(HAVE_DECL_SYS_SIGLIST) && HAVE_DECL_SYS_SIGLIST == 1
# define my_sys_siglist sys_siglist
#elif defined(HAVE_DECL__SYS_SIGLIST) && HAVE_DECL__SYS_SIGLIST == 1
#include "sudo.h"
-#if !defined(NSIG)
-# if defined(_NSIG)
-# define NSIG _NSIG
-# elif defined(__NSIG)
-# define NSIG __NSIG
-# else
-# define NSIG 64
-# endif
-#endif
-
static volatile sig_atomic_t signo[NSIG];
static void handler __P((int));