Avoid re-forking. Fixes bug #20458.

This commit is contained in:
Micah Cowan 2008-05-22 23:40:56 -07:00
parent 9561f6bd2b
commit 3323ed3c17
2 changed files with 11 additions and 7 deletions

View File

@ -1,3 +1,7 @@
2008-05-22 Micah Cowan <micah@cowan.name>
* FTPServer.pm (run): Avoid re-forking. Fixes bug #20458.
2008-04-26 Micah Cowan <micah@cowan.name>
* Makefile.am, Test-proxied-https-auth.px: Added a test for

View File

@ -833,14 +833,14 @@ sub run
print STDERR "got a connection from: $client_ipnum\n" if $log;
# fork off a process to handle this connection.
my $pid = fork();
unless (defined $pid) {
warn "fork: $!";
sleep 5; # Back off in case system is overloaded.
next;
}
# my $pid = fork();
# unless (defined $pid) {
# warn "fork: $!";
# sleep 5; # Back off in case system is overloaded.
# next;
# }
if ($pid == 0) { # Child process.
if (1) { # Child process.
# install signals
$SIG{URG} = sub {