X-Git-Url: http://scm.dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FRoute.pm;h=d4fb95d4205eae5143959c9c6efd130b0da1eb43;hb=0bf3741541e019f34e3723649cf487e9982d978d;hp=1106892a167c8641147ac76fa02d9118a13057eb;hpb=916f0deef0e085647471d5959a55c2ddb815a044;p=spider.git diff --git a/perl/Route.pm b/perl/Route.pm index 1106892a..d4fb95d4 100644 --- a/perl/Route.pm +++ b/perl/Route.pm @@ -298,15 +298,15 @@ sub findroutes return () if $seen->{$call}; if (my $dxchan = DXChannel::get($call)) { $seen->{$call}++; - push @out, [$level, $dxchan]; + push @out, $level ? [$level, $dxchan] : $dxchan; return @out; } # deal with more nodes - my $nref = Route::Node::get($call); - foreach my $ncall (@{$nref->{nodes}}) { + my $nref = Route::get($call); + foreach my $ncall (@{$nref->{parent}}) { dbg("recursing from $call -> $ncall") if isdbg('routec'); - my @rout = findroute($ncall, $level+1, $seen); + my @rout = findroutes($ncall, $level+1, $seen); push @out, @rout; }