if ($r) {
my $ar;
if ($call ne $parent->call) {
- $ar = $parent->add($r);
- push @rout, $ar if $ar;
+ if ($self->in_filter_route($r)) {
+ $ar = $parent->add($call, $ver, $flags);
+ push @rout, $ar if $ar;
+ } else {
+ next;
+ }
}
if ($r->version ne $ver || $r->flags != $flags) {
$r->version($ver);
- $r->flags(Route::here($here)|Route::conf($conf));
+ $r->flags($flags);
push @rout, $r unless $ar;
}
} else {
next if $call eq $main::mycall || $call eq $self->{call};
- my $new = $parent->new($call, $ver, Route::here($here)|Route::conf($conf));
+ my $new = Route->new($call); # throw away
if ($self->in_filter_route($new)) {
- $parent->add($new);
- push @rout, $new;
+ my $r = $parent->add($call, $ver, $flags);
+ push @rout, $r;
} else {
- $new->del($parent);
+ next;
}
}
$ref->here($field[2]) if $ref;
$ref = Route::User::get($call);
$ref->here($field[2]) if $ref;
+ $ref ||= Route->new($call);
# input filter if required
return unless $self->in_filter_route($ref);
}
$user->lastoper($main::systime); # to cut down on excessive for/opers being generated
$user->put;
- my $ref = Route::get($call);
+ my $ref = Route::get($call) || Route->new($call);
# input filter if required
return unless $self->in_filter_route($ref);
# always send it down the local interface if available
my $dxchan = DXChannel->get($call);
unless ($dxchan) {
- my $cl = Route::Node::get($call);
+ my $cl = Route::get($call);
$dxchan = $cl->dxchan if $cl;
if (ref $dxchan) {
if (ref $self && $dxchan eq $self) {
foreach $dxchan (@dxchan) {
next if $dxchan == $self;
next if $dxchan == $me;
- if ($self->{routefilter} || !$self->{isolate}) {
+ if ($dxchan->{routefilter} || !$self->{isolate}) {
$dxchan->send_route($generate, @_)
} else {
dbg('DXPROT: isolated') if isdbg('chanerr');