diff options
-rw-r--r-- | Changelog | 1 | ||||
-rwxr-xr-x | interimap | 4 |
2 files changed, 3 insertions, 2 deletions
@@ -10,6 +10,7 @@ interimap (0.2) upstream default if both the local and remote servers advertize "BINARY". Can be disabled by adding 'use-binary=NO' to the default section in the configuration file. + * Exit with return value 0 when receiving a TERM signal. -- Guilhem Moulin <guilhem@guilhem.org> Wed, 09 Sep 2015 00:44:35 +0200 @@ -118,8 +118,8 @@ sub cleanup() { close $LOGGER_FD if defined $LOGGER_FD; $DBH->disconnect() if defined $DBH; } -$SIG{$_} = sub { msg(undef, $!); cleanup(); exit 1; } foreach qw/INT TERM/; -$SIG{$_} = sub { msg(undef, $!); cleanup(); exit 0; } foreach qw/HUP/; +$SIG{$_} = sub { msg(undef, $!); cleanup(); exit 1; } foreach qw/INT/; +$SIG{$_} = sub { cleanup(); exit 0; } foreach qw/HUP TERM/; ############################################################################# |