projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
get the pc19 and pc20 the correct way around
[spider.git]
/
perl
/
Route
/
Node.pm
diff --git
a/perl/Route/Node.pm
b/perl/Route/Node.pm
index d46733bbcdf295e05aafd649e34262e688fd904a..bd69d3d77290947af5089a73484ebc339cddbfe1 100644
(file)
--- a/
perl/Route/Node.pm
+++ b/
perl/Route/Node.pm
@@
-58,7
+58,7
@@
sub max
# object with that callsign. The upper layers are expected to do something
# sensible with this!
#
# object with that callsign. The upper layers are expected to do something
# sensible with this!
#
-# called as $parent->add(call,
dxchan,
version, flags)
+# called as $parent->add(call, version, flags)
#
sub add
#
sub add
@@
-66,13
+66,21
@@
sub add
my $parent = shift;
my $call = uc shift;
confess "Route::add trying to add $call to myself" if $call eq $parent->{call};
my $parent = shift;
my $call = uc shift;
confess "Route::add trying to add $call to myself" if $call eq $parent->{call};
+ my $version = shift;
+ my $here = shift;
+
my $self = get($call);
if ($self) {
$self->_addparent($parent);
$parent->_addnode($self);
my $self = get($call);
if ($self) {
$self->_addparent($parent);
$parent->_addnode($self);
+ if ($self->{version} != $version || $self->{flags} != $here) {
+ $self->{version} = $version;
+ $self->{flags} = $here;
+ return $self;
+ }
return undef;
}
return undef;
}
- $self = $parent->new($call,
@_
);
+ $self = $parent->new($call,
$version, $here
);
$parent->_addnode($self);
return $self;
}
$parent->_addnode($self);
return $self;
}