fix problem with users on multiple nodes not being propagated
authorminima <minima>
Sun, 19 Jan 2003 17:12:55 +0000 (17:12 +0000)
committerminima <minima>
Sun, 19 Jan 2003 17:12:55 +0000 (17:12 +0000)
Changes
perl/DXProt.pm

diff --git a/Changes b/Changes
index 5e3e1c049de97fe24518ac26b60d6b79cdb0d1d0..7008373b081039e2c0a22b7b75bfa25ae08074f0 100644 (file)
--- a/Changes
+++ b/Changes
@@ -15,6 +15,7 @@ for each 'new' PC16 that the node sees. This is normal and will go away the
 second time the system needs to issue a PC19.
 2. Alter the export_user command to remove users that have no useful info
 and have not been seen for more than (default) 1 year.
+3. fix the problem of users on more than one node not being propagated
 17Jan03=======================================================================
 1. Fix problem with lines being left in the main input queue for a 
 disconnected/ing node.
index efa5ff9b57d5e058eb3ac64c3a727e4296044bda..9c04497680673939c3fc8ca9ac6c3e520e932ed8 100644 (file)
@@ -729,11 +729,13 @@ sub normal
                                my $flags = Route::here($here)|Route::conf($conf);
                                
                                if ($r) {
+                                       my @add;
+                                       push @add, $r->addparent($parent);                                      
                                        if ($r->flags != $flags) {
                                                $r->flags($flags);
-                                               push @rout, $r;
+                                               push @add, $r unless @add;
                                        }
-                                       $r->addparent($parent);
+                                       push @rout, @add;
                                } else {
                                        push @rout, $parent->add_user($call, $flags);
                                }
@@ -1893,8 +1895,8 @@ sub disconnect
                $self->send_now("D", DXProt::pc39($main::mycall, $self->msg('disc1', "System Op")));
        }
 
-       # get rid of any PC16/17/19/21s
-       eph_del_regex("^PC(?:1[679]|21).*$call");
+       # get rid of any PC16/17/19
+       eph_del_regex("^PC1[679]*$call");
 
        # do routing stuff, remove me from routing table
        my $node = Route::Node::get($call);
@@ -1905,7 +1907,7 @@ sub disconnect
                # and all my ephemera as well
                for (@rout) {
                        my $c = $_->call;
-                       eph_del_regex("^PC(?:1[679]|21).*$c");
+                       eph_del_regex("^PC1[679].*$c");
                }
        }
        
@@ -1919,7 +1921,7 @@ sub disconnect
                }
                
                # and the ephemera
-               eph_del_regex("^PC(?:1[679]|21).*$k");
+               eph_del_regex("^PC1[679].*$k");
        }
 
        # unbusy and stop and outgoing mail