Author: radu
Date: Thu Sep 4 04:43:08 2008
New Revision: 942
Modified:
trunk/Changes
trunk/qpsmtpd-prefork
Log:
Clean up exit codes.
Modified: trunk/Changes
==============================================================================
--- trunk/Changes (original)
+++ trunk/Changes Thu Sep 4 04:43:08 2008
@@ -1,3 +1,5 @@
+ prefork: exit codes cleanup (based on patch by Diego d'Ambra)
+
prefork: detect and reset locked shared memory (based on patch by
Diego d'Ambra)
Modified: trunk/qpsmtpd-prefork
==============================================================================
--- trunk/qpsmtpd-prefork (original)
+++ trunk/qpsmtpd-prefork Thu Sep 4 04:43:08 2008
@@ -401,14 +401,14 @@
my $sigset = POSIX::SigSet->new();
my $blockset = POSIX::SigSet->new(SIGCHLD);
sigprocmask(SIG_UNBLOCK, $blockset, $sigset)
- or die "Could not unblock SIGHUP signal: $!\n";
+ or die "Could not unblock SIGCHLD signal: $!\n";
$SIG{CHLD} = $SIG{INT} = $SIG{TERM} = $SIG{ALRM} = 'DEFAULT';
# child should exit if it receives HUP signal (note: blocked while child
# is busy, but restored once done)
$SIG{HUP} = sub {
info("signal HUP received, going to exit");
- exit 1;
+ exit;
};
# continue to accept connections until "old age" is reached
@@ -672,8 +672,8 @@
print $client "421 Connection Timed Out\n";
info("Connection Timed Out");
- # kill the child
- exit 1;
+ # child terminates
+ exit;
};
# set enviroment variables