Leaked source code of windows server 2003
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.

71 lines
2.0 KiB

  1. /***
  2. *signal.h - defines signal values and routines
  3. *
  4. * Copyright (c) 1985-1990, Microsoft Corporation. All rights reserved.
  5. *
  6. *Purpose:
  7. * This file defines the signal values and declares the signal functions.
  8. * [ANSI/System V]
  9. *
  10. ****/
  11. #if defined(_DLL) && !defined(_MT)
  12. #error Cannot define _DLL without _MT
  13. #endif
  14. #ifdef _MT
  15. #define _FAR_ _far
  16. #else
  17. #define _FAR_
  18. #endif
  19. #ifdef _DLL
  20. #define _LOADDS_ _loadds
  21. #else
  22. #define _LOADDS_
  23. #endif
  24. #ifndef _SIG_ATOMIC_T_DEFINED
  25. typedef int sig_atomic_t;
  26. #define _SIG_ATOMIC_T_DEFINED
  27. #endif
  28. #define NSIG 23 /* maximum signal number + 1 */
  29. /* signal types */
  30. /* SIGINT, SIGFPE, SIGILL, SIGSEGV, and SIGABRT are recognized on DOS 3.x */
  31. #define SIGINT 2 /* interrupt - corresponds to DOS 3.x int 23H */
  32. #define SIGILL 4 /* illegal instruction - invalid function image */
  33. #define SIGFPE 8 /* floating point exception */
  34. #define SIGSEGV 11 /* segment violation */
  35. #define SIGTERM 15 /* Software termination signal from kill */
  36. #define SIGUSR1 16 /* User defined signal 1 */
  37. #define SIGUSR2 17 /* User defined signal 2 */
  38. #define SIGUSR3 20 /* User defined signal 3 */
  39. #define SIGBREAK 21 /* Ctrl-Break sequence */
  40. #define SIGABRT 22 /* abnormal termination triggered by abort call */
  41. /* signal action codes */
  42. /* SIG_DFL and SIG_IGN are recognized on DOS 3.x */
  43. #define SIG_DFL (void (_FAR_ _cdecl _LOADDS_ *)())0 /* default signal action */
  44. #define SIG_IGN (void (_FAR_ _cdecl _LOADDS_ *)())1 /* ignore */
  45. #define SIG_SGE (void (_FAR_ _cdecl _LOADDS_ *)())3 /* signal gets error */
  46. #define SIG_ACK (void (_FAR_ _cdecl _LOADDS_ *)())4 /* error if handler not setup */
  47. /* signal error value (returned by signal call on error) */
  48. #define SIG_ERR (void (_FAR_ _cdecl _LOADDS_ *)())-1 /* signal error value */
  49. /* function prototypes */
  50. void (_FAR_ _cdecl _LOADDS_ * _FAR_ _cdecl signal(int,
  51. void (_FAR_ _cdecl _LOADDS_ *)()))();
  52. #ifndef _MT
  53. int _FAR_ _cdecl raise(int);
  54. #endif