make all the subsidiary nodes go as well as the dxchannel ones
[spider.git] / perl / DXMsg.pm
index 3063948a347a9af733100f54e8836a240c05134a..a992f2ae2d5b1597d206bcf4b95f84fc03c2ba32 100644 (file)
@@ -612,10 +612,17 @@ sub queue_msg
 #                              my $hnode =  $uref->homenode if $uref;
 #                              $clref = Route::Node::get($hnode) if $hnode;
 #                      }
-                       if ($clref && !grep { $clref->dxchan == $_ } DXCommandmode::get_all()) {
-                               next if $clref->call eq $main::mycall;  # i.e. it lives here
-                               $dxchan = $clref->dxchan;
-                               $ref->start_msg($dxchan) if $dxchan && !get_busy($dxchan->call)  && $dxchan->state eq 'normal';
+                       if ($clref) {
+                               my $dxc = $clref->dxchan;
+                               if ($dxc) {
+                                       if (!grep $dxc == $_, DXCommandmode::get_all()) {
+                                               next if $clref->call eq $main::mycall;  # i.e. it lives here
+                                               $dxchan = $dxc;
+                                               $ref->start_msg($dxchan) if $dxchan && !get_busy($dxchan->call)  && $dxchan->state eq 'normal';
+                                       }
+                               } else {
+                                       dbg('route', "Route: No dxchan for $ref->{to} " . ref($clref) );
+                               }
                        }
                }