From c2c31aa13a3b7d59bbd319fa24cbb7fcf33daa9a Mon Sep 17 00:00:00 2001 From: Marian Beermann Date: Mon, 26 Dec 2016 15:29:30 +0100 Subject: [PATCH] enable faulthandler --- borg/archiver.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/borg/archiver.py b/borg/archiver.py index 6fa6c5756..7ad2195d8 100644 --- a/borg/archiver.py +++ b/borg/archiver.py @@ -2038,6 +2038,9 @@ def main(): # pragma: no cover # SIGHUP is important especially for systemd systems, where logind # sends it when a session exits, in addition to any traditional use. # 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)), \ signal_handler('SIGHUP', raising_signal_handler(SigHup)), \ signal_handler('SIGTERM', raising_signal_handler(SigTerm)), \