X-Git-Url: http://dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=cmd%2Finit.pl;fp=cmd%2Finit.pl;h=36309e93ab6408d878c99c7bc58fde10adcc3e18;hb=118cbdbcf7e06d022a3030670c0e70b05bd8c5b3;hp=bfcb9bd290a2bca678bc7694cd34e260f8951367;hpb=69e2746d46e5f6095530e76297aeddc1f359d4fb;p=spider.git diff --git a/cmd/init.pl b/cmd/init.pl index bfcb9bd2..36309e93 100644 --- a/cmd/init.pl +++ b/cmd/init.pl @@ -1,6 +1,10 @@ # # reinit a cluster connection # +# Copyright (c) 1999 Dirk Koopman G1TLH +# +# $Id$ +# my ($self, $line) = @_; my @calls = split /\s+/, $line; my $call; @@ -18,12 +22,14 @@ foreach $call (@calls) { # first clear out any nodes on this dxchannel my @gonenodes = map { $_->dxchan == $dxchan ? $_ : () } DXNode::get_all(); foreach my $node (@gonenodes) { - next if $dxchan == $DXProt::me; + next if $node->dxchan == $DXProt::me; + next if $node->dxchan == $dxchan; DXProt::broadcast_ak1a(DXProt::pc21($node->call, 'Gone, re-init') , $dxchan) unless $dxchan->{isolate}; $node->del(); } $dxchan->send(DXProt::pc38()); $dxchan->send(DXProt::pc18()); + $dxchan->state('init'); push @out, $self->msg('init1', $call); } } else {