]> dxcluster.org Git - spider.git/commitdiff
improve PC19 handling
authorminima <minima>
Thu, 14 Jun 2001 22:40:35 +0000 (22:40 +0000)
committerminima <minima>
Thu, 14 Jun 2001 22:40:35 +0000 (22:40 +0000)
perl/DXProt.pm

index d5e886e5a37f33bad133c89146c239c7a8e86824..3767145ca4277463ca60fe172db9b695f57b8320 100644 (file)
@@ -648,22 +648,21 @@ sub normal
                                # update it if required
                                my $r = Route::Node::get($call);
                                my $flags = Route::here($here)|Route::conf($conf);
-                               if ($parent->call eq $call && ($parent->version ne $ver || $parent->flags != $flags)) {
-                                       $parent->version($ver);
-                                       $parent->flags($flags);
-                                       push @rout, $parent;
-                               } elsif ($r) {
-                                       my $ar = $parent->add($r);
-                                       push @rout, $ar if $ar;
+                               if ($r) {
+                                       my $ar;
+                                       if ($call ne $parent->call) {
+                                               $ar = $parent->add($r);
+                                               push @rout, $ar if $ar;
+                                       }
                                        if ($r->version ne $ver || $r->flags != $flags) {
                                                $r->version($ver);
                                                $r->flags(Route::here($here)|Route::conf($conf));
                                                push @rout, $r unless $ar;
                                        }
-                               } elsif ($parent->call ne $call) {
+                               } else {
                                        next if $call eq $main::mycall || $call eq $self->{call};
                                        
-                                       my $new = Route::Node->new($call, $ver, Route::here($here)|Route::conf($conf));
+                                       my $new = $parent->new($call, $ver, Route::here($here)|Route::conf($conf));
                                    if ($self->in_filter_route($new)) {
                                                $parent->add($new);
                                                push @rout, $new;