]> git.donarmstrong.com Git - infobot.git/commitdiff
- on_invite: used 'next' in if statement, changed to commented return
authordms <dms@c11ca15a-4712-0410-83d8-924469b57eb5>
Fri, 28 Dec 2001 14:31:18 +0000 (14:31 +0000)
committerdms <dms@c11ca15a-4712-0410-83d8-924469b57eb5>
Fri, 28 Dec 2001 14:31:18 +0000 (14:31 +0000)
  since validChan is still buggy :/
- verstats: added more ID to possible clients.
- moved debian gz files check to miscCheck, changed interval to 120mins

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

src/IRC/IrcHooks.pl
src/IRC/Schedulers.pl

index 2d03d0cb534829a3bc4dbf54d17fc162c70e2759..a4ffd21a55e6b0edbc9a65041b520a43e26cd083 100644 (file)
@@ -427,9 +427,10 @@ sub on_invite {
 
     ### TODO: join key.
     if (exists $chanconf{$chan}) {
+       # it's still buggy :/
        if (&validChan($chan)) {
            &msg($who, "i'm already in \002$chan\002.");
-           next;
+#          return;
        }
 
        &status("invited to $b_blue$chan$ob by $b_cyan$nick$ob");
@@ -1044,7 +1045,7 @@ sub on_crversion {
     }
 
     if (grep /^\Q$nick\E$/i, @vernick) {
-       &WARN("nick $nick found in vernick; skipping.");
+       &WARN("nick $nick found in vernick ($ver); skipping.");
        return;
     }
     push(@vernick, $nick);
@@ -1058,17 +1059,17 @@ sub on_crversion {
     } elsif ($ver =~ /irssi/i) {
        $ver{irssi}{$nick}      = $ver;
 
-    } elsif ($ver =~ /epic/i) {
+    } elsif ($ver =~ /epic|(Third Eye)/i) {
        $ver{epic}{$nick}       = $ver;
 
     } elsif ($ver =~ /mirc/i) {
-       &DEBUG("verstats: mirc: $nick => '$ver'.");
+#      &DEBUG("verstats: mirc: $nick => '$ver'.");
        $ver{mirc}{$nick}       = $ver;
 
     } elsif ($ver =~ /ircle/i) {
        $ver{ircle}{$nick}      = $ver;
 
-    } elsif ($ver =~ /ircII/i) {
+    } elsif ($ver =~ /ircII|PhoEniX/i) {
        $ver{ircII}{$nick}      = $ver;
 
     } elsif ($ver =~ /sirc /i) {
index b2dd6f9ab51c6730671ca3181eede12c42f7e4b7..3f284cdf9a23450cd974ca90fc83910db9defc65 100644 (file)
@@ -779,10 +779,21 @@ sub ircCheck {
 
 sub miscCheck {
     if (@_) {
-       &ScheduleThis(240, "miscCheck");
+       &ScheduleThis(120, "miscCheck");
        return if ($_[0] eq "2");       # defer.
     }
 
+    # debian check.
+    opendir(DEBIAN, "$bot_state_dir/debian");
+    foreach ( grep /gz$/, readdir(DEBIAN) ) {
+       my $exit = CORE::system("gzip -t $bot_state_dir/debian/$_");
+       next unless ($exit);
+
+       &status("debian: unlinking file => $_");
+       unlink "$bot_state_dir/debian/$_";
+    }
+    closedir DEBIAN;
+
     # SHM check.
     my @ipcs;
     if ( -x "/usr/bin/ipcs") {
@@ -836,17 +847,6 @@ sub miscCheck2 {
        return if ($_[0] eq "2");       # defer.
     }
 
-    # debian check.
-    opendir(DEBIAN, "$bot_state_dir/debian");
-    foreach ( grep /gz$/, readdir(DEBIAN) ) {
-       my $exit = CORE::system("gzip -t $bot_state_dir/debian/$_");
-       next unless ($exit);
-
-       &status("debian: unlinking file => $_");
-       unlink "$bot_state_dir/debian/$_";
-    }
-    closedir DEBIAN;
-
     # compress logs that should have been compressed.
     # todo: use strftime?
     my ($day,$month,$year) = (localtime(time()))[3,4,5];