Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

92 lines
2.0 KiB

  1. /*++
  2. Copyright (c) 1989-1996 Microsoft Corporation
  3. Module Name:
  4. signal.h
  5. Abstract:
  6. This module contains the signal related types and data structures described
  7. in sections 3.3.1 thru 3.3.7 of IEEE P1003.1/Draft 13.
  8. --*/
  9. #ifndef _SIGNAL_
  10. #define _SIGNAL_
  11. #include <sys/types.h>
  12. #ifdef __cplusplus
  13. extern "C" {
  14. #endif
  15. typedef unsigned long sigset_t;
  16. #ifndef _SIG_ATOMIC_T_DEFINED
  17. typedef int sig_atomic_t;
  18. #define _SIG_ATOMIC_T_DEFINED
  19. #endif
  20. #ifdef _WIN64
  21. #define SIG_DFL (void (__cdecl *)(int))0xffffffffffffffff /* default signal action */
  22. #else
  23. #define SIG_DFL (void (__cdecl *)(int))0xffffffff /* default signal action */
  24. #endif
  25. #define SIG_ERR (void (__cdecl *)(int))0 /* signal error value */
  26. #define SIG_IGN (void (__cdecl *)(int))1 /* ignore signal */
  27. #define SIGABRT 1
  28. #define SIGALRM 2
  29. #define SIGFPE 3
  30. #define SIGHUP 4
  31. #define SIGILL 5
  32. #define SIGINT 6
  33. #define SIGKILL 7
  34. #define SIGPIPE 8
  35. #define SIGQUIT 9
  36. #define SIGSEGV 10
  37. #define SIGTERM 11
  38. #define SIGUSR1 12
  39. #define SIGUSR2 13
  40. #define SIGCHLD 14
  41. #define SIGCONT 15
  42. #define SIGSTOP 16
  43. #define SIGTSTP 17
  44. #define SIGTTIN 18
  45. #define SIGTTOU 19
  46. typedef void (__cdecl * _handler)(int);
  47. struct sigaction {
  48. _handler sa_handler;
  49. sigset_t sa_mask;
  50. int sa_flags;
  51. };
  52. #define SA_NOCLDSTOP 0x00000001
  53. #define SIG_BLOCK 1
  54. #define SIG_UNBLOCK 2
  55. #define SIG_SETMASK 3
  56. int __cdecl kill(pid_t, int);
  57. int __cdecl sigemptyset(sigset_t *);
  58. int __cdecl sigfillset(sigset_t *);
  59. int __cdecl sigaddset(sigset_t *, int);
  60. int __cdecl sigdelset(sigset_t *, int);
  61. int __cdecl sigismember(const sigset_t *, int);
  62. int __cdecl sigaction(int, const struct sigaction *, struct sigaction *);
  63. int __cdecl sigprocmask(int, const sigset_t *, sigset_t *);
  64. int __cdecl sigpending(sigset_t *);
  65. int __cdecl sigsuspend(const sigset_t *);
  66. _handler __cdecl signal(int, _handler);
  67. int __cdecl raise(int);
  68. #ifdef __cplusplus
  69. }
  70. #endif
  71. #endif /* _SIGNAL_ */