signals.d.ts 1.1 KB

1234567891011121314151617181920212223242526272829
  1. /// <reference types="node" />
  2. /**
  3. * This is not the set of all possible signals.
  4. *
  5. * It IS, however, the set of all signals that trigger
  6. * an exit on either Linux or BSD systems. Linux is a
  7. * superset of the signal names supported on BSD, and
  8. * the unknown signals just fail to register, so we can
  9. * catch that easily enough.
  10. *
  11. * Windows signals are a different set, since there are
  12. * signals that terminate Windows processes, but don't
  13. * terminate (or don't even exist) on Posix systems.
  14. *
  15. * Don't bother with SIGKILL. It's uncatchable, which
  16. * means that we can't fire any callbacks anyway.
  17. *
  18. * If a user does happen to register a handler on a non-
  19. * fatal signal like SIGWINCH or something, and then
  20. * exit, it'll end up firing `process.emit('exit')`, so
  21. * the handler will be fired anyway.
  22. *
  23. * SIGBUS, SIGFPE, SIGSEGV and SIGILL, when not raised
  24. * artificially, inherently leave the process in a
  25. * state from which it is not safe to try and enter JS
  26. * listeners.
  27. */
  28. export declare const signals: NodeJS.Signals[];
  29. //# sourceMappingURL=signals.d.ts.map