relocating function isProcessRunning to tools.php
This commit is contained in:
parent
54fbbca310
commit
2e6778a27a
2 changed files with 11 additions and 11 deletions
|
@ -19,17 +19,6 @@ function getMMDVMHostFileVersion() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function isProcessRunning($processname) {
|
|
||||||
exec("pgrep " . $processname, $pids);
|
|
||||||
if(empty($pids)) {
|
|
||||||
// process not running!
|
|
||||||
return false;
|
|
||||||
} else {
|
|
||||||
// process running!
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function getMMDVMConfig() {
|
function getMMDVMConfig() {
|
||||||
// loads MMDVM.ini into array for further use
|
// loads MMDVM.ini into array for further use
|
||||||
$mmdvmconfigs = array();
|
$mmdvmconfigs = array();
|
||||||
|
|
|
@ -33,4 +33,15 @@ function getMHZ($freq) {
|
||||||
return substr($freq,0,3) . "." . substr($freq,3,3) . "." . substr($freq,6) . " Mhz";
|
return substr($freq,0,3) . "." . substr($freq,3,3) . "." . substr($freq,6) . " Mhz";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function isProcessRunning($processname) {
|
||||||
|
exec("pgrep " . $processname, $pids);
|
||||||
|
if(empty($pids)) {
|
||||||
|
// process not running!
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
// process running!
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
?>
|
?>
|
Loading…
Reference in a new issue