1. Fix Alias for sh/mydx (so it isn't the same as sh/myfdx).
2. Fix sh/c/n uninitialised variable message
3. Fix (and improve) sh/newc gb7 problem
+22Jun06=======================================================================
+1. Fix Alias for sh/mydx (so it isn't the same as sh/myfdx).
+2. Fix sh/c/n uninitialised variable message
+3. Fix (and improve) sh/newc gb7 problem
21Jun06=======================================================================
1. merge back SIMPLEROUTE branch to issue as official 1.54.
18Jun06=======================================================================
'^sho?w?/fdx/d(\d+)', 'show/dx real from $1', 'show/fdx',
'^sho?w?/fdx', 'show/dx real', 'show/fdx',
'^sho?w?/gre?y?l?i?n?e?', 'show/grayline', 'show/grayline',
- '^sho?w?/myd?x?/(\d+)-(\d+)', 'show/dx filter $1-$2', 'show/mydx',
- '^sho?w?/myd?x?/(\d+)', 'show/dx filter $1', 'show/mydx',
- '^sho?w?/myd?x?/d(\d+)', 'show/dx filter from $1', 'show/mydx',
- '^sho?w?/myd?x?', 'show/dx filter', 'show/mydx',
'^sho?w?/myfd?x?/(\d+)-(\d+)', 'show/dx filter real $1-$2', 'show/mydx',
'^sho?w?/myfd?x?/(\d+)', 'show/dx filter real $1', 'show/mydx',
'^sho?w?/myfd?x?/d(\d+)', 'show/dx filter real from $1', 'show/mydx',
'^sho?w?/myfd?x?', 'show/dx filter real', 'show/mydx',
+ '^sho?w?/myd?x?/(\d+)-(\d+)', 'show/dx filter $1-$2', 'show/mydx',
+ '^sho?w?/myd?x?/(\d+)', 'show/dx filter $1', 'show/mydx',
+ '^sho?w?/myd?x?/d(\d+)', 'show/dx filter from $1', 'show/mydx',
+ '^sho?w?/myd?x?', 'show/dx filter', 'show/mydx',
'^sho?w?/newco?n?\w*/n', 'show/newconfiguration node', 'show/newconfiguration',
'^sho?w?/sta?$', 'show/station', 'show/station',
'^sho?w?/tnc', 'who', 'who',
my $dxchan;
foreach $dxchan (@ch) {
- @val = sort {$a->call cmp $b->call} grep { $_->dxchan == $dxchan } @nodes;
+ @val = sort {$a->call cmp $b->call} grep { $_->dxchan && $_->dxchan == $dxchan } @nodes;
@l = ();
my $call = $dxchan->call;
$call ||= '???';
shift @list;
}
-push @out, $main::routeroot->config($nodes_only, 0, [], @list);
+push @out, $main::routeroot->config($nodes_only, 0, {}, @list);
return (1, @out);
my $t = ztime($_[2]);
my $loc = '';
my $clth = $self->{consort} eq 'local' ? 29 : 30;
- my $comment = substr $_[3], 0, $clth;
+ my $comment = substr (($_[3] || ''), 0, $clth);
$comment .= ' ' x ($clth - length($comment));
- if ($self->{user}->wantgrid) {
+ if ($self->{user}->wantgrid) {
my $ref = DXUser->get_current($_[4]);
if ($ref) {
$loc = $ref->qra || '';
sub config
{
my $self = shift;
- my $nodes_only = shift;
+ my $nodes_only = shift || 0;
my $level = shift;
my $seen = shift;
my @out;
my $line;
- my $call = $self->user_call;
+ my $call = $self->{call};
my $printit = 1;
+ dbg("config: $call nodes: $nodes_only level: $level calls: " . join(',', @_)) if isdbg('routec');
+
# allow ranges
if (@_) {
$printit = grep $call =~ m|$_|, @_;
}
if ($printit) {
- my $pcall = $call;
- $pcall .= ":" . $self->obscount if $self->via_pc92;
+ my $pcall = $self->user_call;
+ $pcall .= ":" . $self->obscount if isdbg('obscount');
$line = ' ' x ($level*2) . "$pcall";
- $call = ' ' x length $pcall;
+ $pcall = ' ' x length $pcall;
# recursion detector
- if ((DXChannel::get($self->{call}) && $level > 1) || grep $self->{call} eq $_, @$seen) {
+ if ((DXChannel::get($call) && $level > 1) || $seen->{$call}) {
$line .= ' ...';
push @out, $line;
return @out;
}
- push @$seen, $self->{call};
+ $seen->{$call}++;
# print users
unless ($nodes_only) {
} else {
$line =~ s/\s+$//;
push @out, $line;
- $line = ' ' x ($level*2) . "$call->$c ";
+ $line = ' ' x ($level*2) . "$pcall->$c ";
}
}
}
$line =~ s/->$//g;
$line =~ s/\s+$//;
push @out, $line if length $line;
+ } else {
+ # recursion detector
+ if ((DXChannel::get($call) && $level > 1) || $seen->{$call}) {
+ return @out;
+ }
+ $seen->{$call}++;
}
# deal with more nodes
if ($nref) {
my $c = $nref->user_call;
-# dbg("recursing from $call -> $c") if isdbg('routec');
- push @out, $nref->config($nodes_only, $level+1, $seen, @_);
+ dbg("recursing from $call -> $c") if isdbg('routec');
+ my @rout = $nref->config($nodes_only, $level+1, $seen, @_);
+ if (@rout && @_) {
+ push @out, ' ' x ($level*2) . $self->user_call unless grep /^\s+$call/, @out;
+ }
+ push @out, @rout;
} else {
push @out, ' ' x (($level+1)*2) . "$ncall?" if @_ == 0 || (@_ && grep $ncall =~ m|$_|, @_);
}
$version = '1.54';
$subversion = '0';
-$build = '59';
+$build = '60';
1;