From 6d6cbdf4c7b4a30a8353d913a50c8d9cd497fcdb Mon Sep 17 00:00:00 2001
From: tbrehm <t.brehm@ispconfig.org>
Date: Wed, 27 Oct 2010 14:07:20 -0400
Subject: [PATCH] Fixed php warnings.

---
 server/plugins-available/apache2_plugin.inc.php |    2 +-
 server/lib/classes/system.inc.php               |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/server/lib/classes/system.inc.php b/server/lib/classes/system.inc.php
index 722ae63..5de2f81 100644
--- a/server/lib/classes/system.inc.php
+++ b/server/lib/classes/system.inc.php
@@ -1209,7 +1209,7 @@
 		$maildirsubs = array('cur','new','tmp');
 
 		foreach ($maildirsubs as $mdsub) {
-			mkdir($dir.'/'.$mdsub, 0700, true);
+			if(!is_dir($dir.'/'.$mdsub)) mkdir($dir.'/'.$mdsub, 0700, true);
 			if ($chown_mdsub) {
 				chown($dir.'/'.$mdsub, $user);
 				chgrp($dir.'/'.$mdsub, $group);
diff --git a/server/plugins-available/apache2_plugin.inc.php b/server/plugins-available/apache2_plugin.inc.php
index 220d0cd..374d4e5 100644
--- a/server/plugins-available/apache2_plugin.inc.php
+++ b/server/plugins-available/apache2_plugin.inc.php
@@ -915,7 +915,7 @@
 		}
 		
 		// Remove the backup copy of the config file.
-		unlink($vhost_file.'~');
+		if(@is_file($vhost_file.'~')) unlink($vhost_file.'~');
 		
 
 		//* Unset action to clean it for next processed vhost.

--
Gitblit v1.9.1