enable faulthandler

This commit is contained in:
Marian Beermann 2016-12-26 15:29:30 +01:00
parent 0ff76bdc9d
commit c2c31aa13a
1 changed files with 3 additions and 0 deletions

View File

@ -2038,6 +2038,9 @@ def main(): # pragma: no cover
# SIGHUP is important especially for systemd systems, where logind # SIGHUP is important especially for systemd systems, where logind
# sends it when a session exits, in addition to any traditional use. # sends it when a session exits, in addition to any traditional use.
# Output some info if we receive SIGUSR1 or SIGINFO (ctrl-t). # Output some info if we receive SIGUSR1 or SIGINFO (ctrl-t).
# Register fault handler for SIGSEGV, SIGFPE, SIGABRT, SIGBUS and SIGILL.
faulthandler.enable()
with signal_handler('SIGINT', raising_signal_handler(KeyboardInterrupt)), \ with signal_handler('SIGINT', raising_signal_handler(KeyboardInterrupt)), \
signal_handler('SIGHUP', raising_signal_handler(SigHup)), \ signal_handler('SIGHUP', raising_signal_handler(SigHup)), \
signal_handler('SIGTERM', raising_signal_handler(SigTerm)), \ signal_handler('SIGTERM', raising_signal_handler(SigTerm)), \