From 3dd40bf97c45c4cb2cc40e9f20796a799f4e1255 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Thu, 10 Sep 2009 21:22:07 -0700 Subject: Trim the input line to get rid of carriage returns on Windows. Fixes ticket #740. Thanks to jankoprowski! --- installer/installer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'installer') diff --git a/installer/installer.php b/installer/installer.php index 4480e35e..7a417634 100644 --- a/installer/installer.php +++ b/installer/installer.php @@ -60,7 +60,7 @@ class installer { $prefix = $config["prefix"]; $buf = null; foreach (file(DOCROOT . "installer/install.sql") as $line) { - $buf .= $line; + $buf .= trim($line); if (preg_match("/;$/", $buf)) { if (!mysql_query(self::prepend_prefix($prefix, $buf))) { return false; -- cgit v1.2.3