projects
/
spider.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b7a0598
)
some fixed
author
minima
<minima>
Fri, 8 Jun 2001 20:19:33 +0000
(20:19 +0000)
committer
minima
<minima>
Fri, 8 Jun 2001 20:19:33 +0000
(20:19 +0000)
perl/DXProt.pm
patch
|
blob
|
history
perl/Route.pm
patch
|
blob
|
history
diff --git
a/perl/DXProt.pm
b/perl/DXProt.pm
index f4c932a81cfe35847ab354fa79c0a4b4b4174de9..e33488ccaf9942c5cdca015e66e0ff74f936078a 100644
(file)
--- a/
perl/DXProt.pm
+++ b/
perl/DXProt.pm
@@
-642,6
+642,8
@@
sub normal
$node->flags(Route::here($here)|Route::conf($conf));
push @rout, $node;
} elsif ($node->call ne $call) {
$node->flags(Route::here($here)|Route::conf($conf));
push @rout, $node;
} elsif ($node->call ne $call) {
+ next if $call eq $main::mycall || $call eq $self->{call};
+
my $r = $node->add($call, $ver, Route::here($here)|Route::conf($conf));
push @rout, $r if $r;
}
my $r = $node->add($call, $ver, Route::here($here)|Route::conf($conf));
push @rout, $r if $r;
}
@@
-1691,7
+1693,7
@@
sub send_route
$routeit = adjust_hops($self, $line); # adjust its hop count by node name
next unless $routeit;
}
$routeit = adjust_hops($self, $line); # adjust its hop count by node name
next unless $routeit;
}
- $self->send($routeit)
unless $self->{isolate} || $self->{isolate}
;
+ $self->send($routeit);
}
}
}
}
}
}
diff --git
a/perl/Route.pm
b/perl/Route.pm
index 3f940426f4068ffb1e7242de41765eff645b5125..0150d5bfd3b92b7c7d3cf8c391ce30ca1f089756 100644
(file)
--- a/
perl/Route.pm
+++ b/
perl/Route.pm
@@
-232,18
+232,21
@@
sub get
sub alldxchan
{
my $self = shift;
sub alldxchan
{
my $self = shift;
-
+ my @dxchan;
my $dxchan = DXChannel->get($self->{call});
my $dxchan = DXChannel->get($self->{call});
- if ($dxchan) {
- return (grep $dxchan == $_, @_) ? () : ($dxchan);
- }
+ push @dxchan, $dxchan if $dxchan;
# it isn't, build up a list of dxchannels and possible ping times
# for all the candidates.
# it isn't, build up a list of dxchannels and possible ping times
# for all the candidates.
- my @dxchan = @_;
foreach my $p (@{$self->{parent}}) {
foreach my $p (@{$self->{parent}}) {
- my $ref = $self->get($p);
- push @dxchan, $ref->alldxchan(@dxchan) if $ref;
+ my $dxchan = DXChannel->get($p);
+ if ($dxchan) {
+ push @dxchan, $dxchan if grep $dxchan ne $_, @dxchan;
+ } else {
+ next if $p eq $main::mycall; # the root
+ my $ref = $self->get($p);
+ push @dxchan, $ref->alldxchan if $ref;
+ }
}
return @dxchan;
}
}
return @dxchan;
}
@@
-251,7
+254,9
@@
sub alldxchan
sub dxchan
{
my $self = shift;
sub dxchan
{
my $self = shift;
- my $dxchan;
+ my $dxchan = DXChannel->get($self->{call});
+ return $dxchan = $dxchan;
+
my @dxchan = $self->alldxchan;
return undef unless @dxchan;
my @dxchan = $self->alldxchan;
return undef unless @dxchan;