From dc48ab33efda6f56c30d408182cfec868ef4d91f Mon Sep 17 00:00:00 2001
From: xaver <xaver@ispconfig3>
Date: Sat, 24 Mar 2012 09:01:29 -0400
Subject: [PATCH] Bug #2143, wrong filter url

---
 server/mods-available/monitor_core_module.inc.php |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/server/mods-available/monitor_core_module.inc.php b/server/mods-available/monitor_core_module.inc.php
index ec85bed..bfb03be 100644
--- a/server/mods-available/monitor_core_module.inc.php
+++ b/server/mods-available/monitor_core_module.inc.php
@@ -120,6 +120,13 @@
         global $app;
 
         /*
+		 *  This monitoring is expensive, so do it only every 15 minutes
+		 */
+		$min = @date('i');
+		if ($min % 15 != 0) return;
+		
+		
+		/*
          * First we get the Monitoring-data from the tools
          */
         $res = $this->_tools->monitorEmailQuota();
@@ -406,6 +413,9 @@
 		 * First we get the Monitoring-data from the tools
 		 */
 		$res = $this->_tools->monitorSystemUpdate();
+		
+		//* Ensure that output is encoded so that it does not break the serialize
+		$res['data']['output'] = htmlentities($res['data']['output']);
 
 		/*
 		 * Insert the data into the database
@@ -692,6 +702,9 @@
 		 * First we get the Monitoring-data from the tools
 		 */
 		$res = $this->_tools->monitorISPCCronLog();
+		
+		//* Ensure that output is encoded so that it does not break the serialize
+		$res['data']['output'] = htmlentities($res['data']['output']);
 
 		/*
 		 * Insert the data into the database

--
Gitblit v1.9.1