X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FMsg.pm;h=3a422c3a817c4c93fe32fdd1c1f2f281c5a61e0f;hb=9128a77e1390d3ad788470aaf73a7ce6f9c64c78;hp=815937963962169d8fb2e4d8e0808cb8675bc2a4;hpb=3f64c5686df118fa3f3a1d66a87f25b89eb1732a;p=spider.git diff --git a/perl/Msg.pm b/perl/Msg.pm index 81593796..3a422c3a 100644 --- a/perl/Msg.pm +++ b/perl/Msg.pm @@ -134,9 +134,9 @@ sub pid_gone my ($pkg, $pid) = @_; my @pid = grep {$_->{pid} == $pid} values %conns; - for (@pid) { - &{$_->{eproc}}($_, "$pid has gorn") if exists $_->{eproc}; - $_->disconnect; + foreach my $p (@pid) { + &{$p->{eproc}}($p, "$pid has gorn") if exists $p->{eproc}; + $p->disconnect; } } @@ -436,8 +436,8 @@ sub close_server # close all clients (this is for forking really) sub close_all_clients { - for (values %conns) { - $_->disconnect; + foreach my $conn (values %conns) { + $conn->disconnect; } }