From 132081c0e69f0313ccb0d23637499e940d29f470 Mon Sep 17 00:00:00 2001 From: Marius Cramer <m.cramer@pixcept.de> Date: Fri, 26 Sep 2014 11:57:38 -0400 Subject: [PATCH] - added check for mysql error to avoid flood of error messages/mails --- server/lib/app.inc.php | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/server/lib/app.inc.php b/server/lib/app.inc.php index a1e75af..a9d47a5 100755 --- a/server/lib/app.inc.php +++ b/server/lib/app.inc.php @@ -35,6 +35,7 @@ var $loaded_modules = array(); var $loaded_plugins = array(); + var $_calling_script = ''; function __construct() { @@ -60,6 +61,23 @@ } + function setCaller($caller) { + $this->_calling_script = $caller; + } + + function getCaller() { + return $this->_calling_script; + } + + function forceErrorExit($errmsg = 'undefined') { + global $conf; + + if($this->_calling_script == 'server') { + @unlink($conf['temppath'] . $conf['fs_div'] . '.ispconfig_lock'); + } + die('Exiting because of error: ' . $errmsg); + } + function uses($classes) { global $conf; -- Gitblit v1.9.1