X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXProtHandle.pm;h=cb13e37c652b77ba86d7b5ab0332a6c482c8a5fe;hb=a48eea32af123b571889f70a3e7cef8e157cf389;hp=f28de6d065cbae54941df6703de4e9ed55a26248;hpb=e72ce56ce6973656acb064366459d54cda85f8cc;p=spider.git diff --git a/perl/DXProtHandle.pm b/perl/DXProtHandle.pm index f28de6d0..cb13e37c 100644 --- a/perl/DXProtHandle.pm +++ b/perl/DXProtHandle.pm @@ -46,6 +46,7 @@ use vars qw($pc11_max_age $pc23_max_age $last_pc50 $eph_restime $eph_info_restim $eph_pc15_restime $pc9x_past_age $pc9x_dupe_age $pc10_dupe_age $pc92_slug_changes $last_pc92_slug $pc92Ain $pc92Cin $pc92Din $pc92Kin $pc9x_time_tolerance + $pc92filterdef ); $pc9x_dupe_age = 60; # catch loops of circular (usually) D records @@ -57,6 +58,15 @@ $pc9x_past_age = (122*60)+ # maximum age in the past of a px9x (a config record $pc9x_time_tolerance; # thing a node might send - once an hour and we allow an extra hour for luck) # this is actually the partition between "yesterday" and "today" but old. +$pc92filterdef = bless ([ + # tag, sort, field, priv, special parser + ['call', 'c', 0], + ['by', 'c', 0], + ['dxcc', 'nc', 1], + ['itu', 'ni', 2], + ['zone', 'nz', 3], + ], 'Filter::Cmd'); + # incoming talk commands sub handle_10 @@ -226,7 +236,7 @@ sub handle_11 # # fix up qra locators of known users - my $user = DXUser->get_current($spot[4]); + my $user = DXUser::get_current($spot[4]); if ($user) { my $qra = $user->qra; unless ($qra && is_qra($qra)) { @@ -463,7 +473,7 @@ sub handle_16 # reject this if we think it is a node already my $r = Route::Node::get($call); - my $u = DXUser->get_current($call) unless $r; + my $u = DXUser::get_current($call) unless $r; if ($r || ($u && $u->is_node)) { dbg("PCPROT: $call is a node") if isdbg('chanerr'); next; @@ -485,7 +495,7 @@ sub handle_16 } # add this station to the user database, if required - my $user = DXUser->get_current($ncall); + my $user = DXUser::get_current($ncall); $user = DXUser->new($call) unless $user; $user->homenode($parent->call) if !$user->homenode; $user->node($parent->call); @@ -568,7 +578,7 @@ sub handle_17 $parent->del_user($uref); # send info to all logged in thingies - my $user = DXUser->get_current($ncall); + my $user = DXUser::get_current($ncall); $self->tell_login('logoutu', "$ncall: $ucall") if $user && $user->is_local_node; $self->tell_buddies('logoutb', $ucall, $ncall); @@ -638,7 +648,7 @@ sub check_add_node my $call = shift; # add this station to the user database, if required (don't remove SSID from nodes) - my $user = DXUser->get_current($call); + my $user = DXUser::get_current($call); if (!$user) { $user = DXUser->new($call); $user->priv(1); # I have relented and defaulted nodes @@ -1142,7 +1152,7 @@ sub handle_41 } # add this station to the user database, if required - my $user = DXUser->get_current($call); + my $user = DXUser::get_current($call); $user = DXUser->new($call) unless $user; if ($sort == 1) { @@ -1709,7 +1719,7 @@ sub handle_92 } } elsif ($sort eq 'K') { - $pc92Kin += length $line if $sort eq 'K'; + $pc92Kin += length $line; # remember the last channel we arrived on $parent->PC92C_dxchan($self->{call}) unless $self->{call} eq $parent->call;