pid of cronjob is the part after the last dash (we did not have more then one before), fixes #1483

Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann (d00p)
2015-02-02 16:13:07 +01:00
parent 48eaab89ba
commit 6df6fc2361

View File

@@ -118,7 +118,7 @@ while ($fName = readdir($lockDirHandle)) {
}
// Check if cron is running or has died.
$check_pid = substr(strstr($fName, "-"), 1);
$check_pid = substr(strrchr($fName, "-"), 1);
system("kill -CHLD " . (int)$check_pid . " 1> /dev/null 2> /dev/null", $check_pid_return);
if ($check_pid_return == 1) {