From 183573e742b5233e3b7ac6882770d16942a10542 Mon Sep 17 00:00:00 2001 From: minima Date: Sat, 9 Jun 2001 03:04:21 +0000 Subject: [PATCH] more fixes --- perl/DXMsg.pm | 9 ++++----- perl/DXProt.pm | 2 +- perl/Route.pm | 4 ++-- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/perl/DXMsg.pm b/perl/DXMsg.pm index a992f2ae..3ca75689 100644 --- a/perl/DXMsg.pm +++ b/perl/DXMsg.pm @@ -613,12 +613,11 @@ sub queue_msg # $clref = Route::Node::get($hnode) if $hnode; # } if ($clref) { - my $dxc = $clref->dxchan; - if ($dxc) { - if (!grep $dxc == $_, DXCommandmode::get_all()) { + $dxchan = $clref->dxchan; + if ($dxchan) { + if ($dxchan->is_node) { next if $clref->call eq $main::mycall; # i.e. it lives here - $dxchan = $dxc; - $ref->start_msg($dxchan) if $dxchan && !get_busy($dxchan->call) && $dxchan->state eq 'normal'; + $ref->start_msg($dxchan) if !get_busy($dxchan->call) && $dxchan->state eq 'normal'; } } else { dbg('route', "Route: No dxchan for $ref->{to} " . ref($clref) ); diff --git a/perl/DXProt.pm b/perl/DXProt.pm index 93cea623..7df2ce24 100644 --- a/perl/DXProt.pm +++ b/perl/DXProt.pm @@ -1384,7 +1384,7 @@ sub send_local_config my $ref = Route::Node::get($self->{call}); my @rnodes = $ref->nodes; for my $n (@intcalls) { - push @remotenodes, Route::Node::get($n) unless grep $n == $_, @rnodes; + push @remotenodes, Route::Node::get($n) unless grep $n eq $_, @rnodes; } unshift @localnodes, $main::routeroot; } diff --git a/perl/Route.pm b/perl/Route.pm index 0150d5bf..b5c02f09 100644 --- a/perl/Route.pm +++ b/perl/Route.pm @@ -241,7 +241,7 @@ sub alldxchan foreach my $p (@{$self->{parent}}) { my $dxchan = DXChannel->get($p); if ($dxchan) { - push @dxchan, $dxchan if grep $dxchan ne $_, @dxchan; + push @dxchan, $dxchan unless grep $dxchan == $_, @dxchan; } else { next if $p eq $main::mycall; # the root my $ref = $self->get($p); @@ -255,7 +255,7 @@ sub dxchan { my $self = shift; my $dxchan = DXChannel->get($self->{call}); - return $dxchan = $dxchan; + return $dxchan if $dxchan; my @dxchan = $self->alldxchan; return undef unless @dxchan; -- 2.34.1