From a0f4840a203c7c83790bb8a4e119ac3d0dcffab5 Mon Sep 17 00:00:00 2001 From: Benjamin Sonntag Date: Thu, 16 Jun 2011 09:01:06 +0000 Subject: [PATCH] fixing 1.0.1 bug with domain lock + fixing deprecated function in php (TO BE CHECKED...) --- bureau/class/config.php | 2 +- install/upgrades/1.0.1.php | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/bureau/class/config.php b/bureau/class/config.php index 1abf758d..f6f70383 100644 --- a/bureau/class/config.php +++ b/bureau/class/config.php @@ -131,7 +131,7 @@ $classes=array(); /* CLASSES PHP : automatic include : */ $c=opendir($root."class/"); while ($di=readdir($c)) { - if (ereg("^m_(.*)\\.php$",$di,$match)) { // $ + if (preg_match("#^m_(.*)\\.php$#",$di,$match)) { // $ $name1="m_".$match[1]; $name2=$match[1]; $classes[]=$name2; diff --git a/install/upgrades/1.0.1.php b/install/upgrades/1.0.1.php index e880a932..9946732e 100644 --- a/install/upgrades/1.0.1.php +++ b/install/upgrades/1.0.1.php @@ -14,6 +14,7 @@ require("/var/alternc/bureau/class/config_nochk.php"); // we go super-admin $admin->enabled=1; +$dom->lock(); // And we process the database changes : $db->query("SELECT * FROM domaines;"); @@ -29,4 +30,7 @@ foreach($domains as $v) { } } +$dom->unlock(); + + ?> \ No newline at end of file