- typo in ignoreAdd; use makeHostMask.
git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk@532
c11ca15a-4712-0410-83d8-
924469b57eb5
# todo: make forget limit configurable.
# todo: make forget ignore time configurable.
if ($cache{forget}{$h} > 5) {
- &ignoreAdd($mask{nuh}, "*", 3*24*60*60, "abuse of forget");
+ &ignoreAdd(&makeHostMask($nuh), "*", 3*24*60*60, "abuse of forget");
&msg($who, "forget: Suck it!");
}
}
if ($host =~ s/^(\S+!\S+\@)//) {
&DEBUG("mHM: detected nick!user\@ for host arg; fixing");
+ &DEBUG("nu => $nu");
$nu = $1;
}
next unless ($time > $forker_timeout);
### TODO: use &time2string()?
- &WARN("Fork: looks like we lost '$_', executed $time ago.");
- delete $forked{$_};
+ &WARN("Fork: looks like we lost '$_', executed $time ago");
+
+ if ( -d "/proc/$forked{$name}{PID}") {
+ my $pid = $forked{$name}{PID};
+ &status("Fork: killing $name ($pid)");
+ kill 9, $pid;
+ }
+
+ delete $forked{$name};
}
my $count = 0;