From 042366b55be1922369f633a2eb9f2a2b86e85fb9 Mon Sep 17 00:00:00 2001 From: Pragmatic Software Date: Wed, 14 Apr 2010 00:01:42 +0000 Subject: [PATCH] Overwhelm was too sensitive --- PBot/IgnoreList.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/PBot/IgnoreList.pm b/PBot/IgnoreList.pm index 70344563..bc25e00a 100644 --- a/PBot/IgnoreList.pm +++ b/PBot/IgnoreList.pm @@ -151,15 +151,15 @@ sub check_ignore { if(not exists $self->{last_timestamp}->{$channel}) { $self->{last_timestamp}->{$channel} = $now; - } elsif($now - $self->{last_timestamp}->{$channel} >= 15) { + } elsif($now - $self->{last_timestamp}->{$channel} >= 30) { $self->{last_timestamp}->{$channel} = $now; if($self->{ignore_flood_counter}->{$channel} > 0) { - $self->{ignore_flood_counter}->{$channel}--; - $pbot->logger->log("flood_msg decremented to $self->{ignore_flood_counter}->{$channel}\n"); + $self->{ignore_flood_counter}->{$channel} = 0; + $pbot->logger->log("flood_msg reset"); } } - if(($self->{ignore_flood_counter}->{$channel} > 5) or ($channel =~ /^#osdev$/i and $self->{ignore_flood_counter}->{$channel} >= 3)) { + if(($self->{ignore_flood_counter}->{$channel} > 5) or ($channel =~ /^#osdev$/i and $self->{ignore_flood_counter}->{$channel} >= 4)) { $pbot->logger->log("flood_msg exceeded! [$self->{ignore_flood_counter}->{$channel}]\n"); $self->{pbot}->{ignorelistcmds}->ignore_user("", "floodcontrol", "", "", ".* $channel 300"); $self->{ignore_flood_counter}->{$channel} = 0;