From 26f79907f62adc7655302bf9889d7573da96ade4 Mon Sep 17 00:00:00 2001 From: minima Date: Sun, 19 Jan 2003 22:50:22 +0000 Subject: [PATCH] make sure we really do have a parent in PC16s mangle pc41 dups to remove deubious characters --- Changes | 3 +++ perl/DXProt.pm | 10 ++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/Changes b/Changes index 7008373b..56326cca 100644 --- a/Changes +++ b/Changes @@ -16,6 +16,9 @@ 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 +4. remove spaces and all non-US ascii characters from PC41 for the dup check. +5. put in check to see if the parent of a newly allowed PC19 is still there +(this needs further investigation). 17Jan03======================================================================= 1. Fix problem with lines being left in the main input queue for a disconnected/ing node. diff --git a/perl/DXProt.pm b/perl/DXProt.pm index ab989c8f..2fe92625 100644 --- a/perl/DXProt.pm +++ b/perl/DXProt.pm @@ -670,7 +670,7 @@ sub normal $parent = Route::Node::get($_->[0]); $dxchan = $parent->dxchan if $parent; if ($dxchan && $dxchan ne $self) { - dbg("PCPROT: PC16 from $self->{call} trying to alter locally connected $ncall, ignored!") if isdbg('chanerr'); + dbg("PCPROT: PC19 from $self->{call} trying to alter locally connected $ncall, ignored!") if isdbg('chanerr'); $parent = undef; } if ($parent) { @@ -685,6 +685,10 @@ sub normal # route the pc19 - this will cause 'stuttering PC19s' for a while $self->route_pc19(@nrout) if @nrout ; $parent = Route::Node::get($ncall); + unless ($parent) { + dbg("PCPROT: lost $ncall after sending PC19 for it?"); + return; + } } else { return; } @@ -1141,7 +1145,9 @@ sub normal if ($pcno == 41) { # user info my $call = $field[1]; - if (eph_dup($line, $eph_info_restime)) { + my $l = $line; + $l =~ s/[\x00-\x20\x7f-\xff]+//g; # remove all funny characters and spaces for dup checking + if (eph_dup($l, $eph_info_restime)) { dbg("PCPROT: dupe") if isdbg('chanerr'); return; } -- 2.43.0