Fixed detection of an installed wcf during the installation
authorRouL <roul@codingcorner.info>
Sun, 17 Jul 2011 03:07:28 +0000 (05:07 +0200)
committerRouL <roul@codingcorner.info>
Sun, 17 Jul 2011 03:07:28 +0000 (05:07 +0200)
Fixed a bug that recognized the installation files in a nested
tmp-directory as an already installed WCF instance at the "choose
folder" page.

wcfsetup/install/files/lib/system/WCFSetup.class.php

index 25e40835b3c0154bfb8981bbaddb5ccbe0a2892b..47db97eeb64f3a4c21b08636ea37499d9609997f 100644 (file)
@@ -382,6 +382,11 @@ class WCFSetup extends WCF {
                else {\r
                        if ($foundDirectory = FileUtil::scanFolder(INSTALL_SCRIPT_DIR, "WCF.class.php", true)) {\r
                                $foundDirectory = $wcfDir = FileUtil::unifyDirSeperator(dirname(dirname(dirname($foundDirectory))).'/');\r
+                               \r
+                               if (dirname(dirname($wcfDir)).'/' == TMP_DIR) {\r
+                                       $foundDirectory = false;\r
+                                       $wcfDir = FileUtil::unifyDirSeperator(INSTALL_SCRIPT_DIR).'wcf/';\r
+                               }\r
                        }\r
                        else {\r
                                $wcfDir = FileUtil::unifyDirSeperator(INSTALL_SCRIPT_DIR).'wcf/';\r