mirror of
https://github.com/oneoffdallas/pfsense-nagios-checks.git
synced 2026-02-05 22:55:16 +01:00
Fix issue with PHP error written to system.log
Thanks for the recommendation @oraclesod
This commit is contained in:
@@ -9,7 +9,15 @@
|
|||||||
# Modified 17 Oct 2019
|
# Modified 17 Oct 2019
|
||||||
|
|
||||||
require_once("pkg-utils.inc");
|
require_once("pkg-utils.inc");
|
||||||
$system_pkg_version = get_system_pkg_version();
|
global $g;
|
||||||
|
|
||||||
|
if (file_exists("{$g['varrun_path']}/pkg.dirty")) {
|
||||||
|
$system_pkg_version = get_system_pkg_version(false,false);
|
||||||
|
} else {
|
||||||
|
shell_exec("sudo touch "."{$g['varrun_path']}/pkg.dirty");
|
||||||
|
$system_pkg_version = get_system_pkg_version(false,false);
|
||||||
|
shell_exec("sudo rm " . "{$g['varrun_path']}/pkg.dirty");
|
||||||
|
}
|
||||||
|
|
||||||
$current_installed_buildtime = trim(file_get_contents("/etc/version.buildtime"));
|
$current_installed_buildtime = trim(file_get_contents("/etc/version.buildtime"));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user