X-Git-Url: http://gb7djk.dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fannounce.pl;h=a3ccb5b033d7f98dc8a9044212c40f0c3e38dcdc;hb=e0fa9a04bfb66136a2485246c7ea1ec8f00e00e2;hp=5e0ff58c998c4c1c440d3a6a66ac66d0698ae4e8;hpb=5f2487385b59dbe88dc763fa9c26fe5a9b4a6b30;p=spider.git diff --git a/cmd/announce.pl b/cmd/announce.pl index 5e0ff58c..a3ccb5b0 100644 --- a/cmd/announce.pl +++ b/cmd/announce.pl @@ -48,10 +48,24 @@ if ($sort eq "FULL") { # change ^ into : for transmission $line =~ s/\^/:/og; +# if this is a 'bad spotter' user then ignore it +my $nossid = $from; +my $drop = 0; +$nossid =~ s/-\d+$//; +if ($DXProt::badspotter->in($nossid)) { + LogDbg('DXCommand', "bad spotter ($self->{call}) made announcement: $line"); + $drop++; +} + +# have they sworn? my @bad; if (@bad = BadWords::check($line)) { $self->badcount(($self->badcount||0) + @bad); - Log('DXCommand', "$self->{call} swore: $line"); + LogDbg('DXCommand', "$self->{call} swore: $line (with words:" . join(',', @bad) . ")"); + $drop++; +} + +if ($drop) { Log('ann', $to, $from, "[to $from only] $line"); $self->send("To $to de $from <$t>: $line"); return (1, ());