]> git.donarmstrong.com Git - infobot.git/commitdiff
fixed the following bugs:
authordms <dms@c11ca15a-4712-0410-83d8-924469b57eb5>
Wed, 18 Apr 2001 14:41:26 +0000 (14:41 +0000)
committerdms <dms@c11ca15a-4712-0410-83d8-924469b57eb5>
Wed, 18 Apr 2001 14:41:26 +0000 (14:41 +0000)
[57419] on_ttf: X1 Target change too fast. Please wait 50 seconds.
[57604] !WARN! IsChanConf: lowercased chan. (Read error to
boren-[adsl-63-197-68-132.dsl.snfc21.pacbell.net]: EOF from client)

git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk/blootbot@448 c11ca15a-4712-0410-83d8-924469b57eb5

src/IRC/IrcHooks.pl

index d8483ef96b69dbfe9cdd0be92803c6350f279721..db2365376c836c49b6e8920976976cf7f73dc3aa 100644 (file)
@@ -789,7 +789,7 @@ sub on_quit {
     # hack for ICC.
     $msgType   = "public";
     $who       = $nick;
-    $chan      = $reason;      # not in split!
+###    $chan   = $reason;      # no.
 
     my $count  = 0;
     foreach (keys %channels) {
@@ -847,12 +847,16 @@ sub on_targettoofast {
     my($me,$chan,$why) = $event->args();
 
     ### TODO: incomplete.
-###    .* wait (\d+) second/) {
-       &status("on_ttf: X1 $why") if (defined $why);
-       my $sleep = 5;
+    if ($why =~ /.* wait (\d+) second/) {
+       my $sleep = $1;
        &status("targettoofast: going to sleep for $sleep...");
        sleep $sleep;
-### }
+    } else {
+       if (!exists $cache{TargetTooFast}) {
+           &DEBUG("on_ttf: failed: $why");
+           $cache{TargetTooFast}++;
+       }
+    }
 }
 
 sub on_topic {