cheat for now
[spider.git] / perl / DXProt.pm
index 3720008a03eb75770b9f7578251d54e20bc57317..875d2b6694314691dd9b219ae03401227870bfdd 100644 (file)
@@ -1664,9 +1664,11 @@ sub disconnect
 
        # do routing stuff
        my $node = Route::Node::get($call);
-       my @rout = $node->del_nodes;    # at the next level
-
-       @rout = $node->del($main::routeroot) if $node;
+       my @rout;
+       if ($node) {
+               @rout = $node->del_nodes;    # at the next level
+               @rout = $node->del($main::routeroot);
+       }
        
        # unbusy and stop and outgoing mail
        my $mref = DXMsg::get_busy($call);
@@ -1718,8 +1720,12 @@ sub send_route
        if ($self->{routefilter}) {
                for (; @_ && $no; $no--) {
                        my $r = shift;
-                       ($filter, $hops) = $self->{routefilter}->it($self->{call}, $self->{dxcc}, $self->{itu}, $self->{cq}, $r->call, $r->dxcc, $r->itu, $r->cq);
-                       push @rin, $r if $filter;
+                       if ($r) {
+                               ($filter, $hops) = $self->{routefilter}->it($self->{call}, $self->{dxcc}, $self->{itu}, $self->{cq}, $r->call, $r->dxcc, $r->itu, $r->cq);
+                               push @rin, $r if $filter;
+                       } else {
+                               dbg('chan', "was sent a null value");
+                       }
                }
        }
        if (@rin) {