From 99f9b9a70a153c93705033b5be81d5d666468675 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Wed, 30 Oct 2013 23:07:23 +0200 Subject: Escape PCRE delimiters --- system/core/Output.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/system/core/Output.php b/system/core/Output.php index cae1347bc..0b11a5abc 100644 --- a/system/core/Output.php +++ b/system/core/Output.php @@ -868,7 +868,7 @@ class CI_Output { { $patterns = array( '#\n?//[^\n]*#' => '', // Remove // line comments - '#\s*([!#%&()*+,\-./:;<=>?@\[\]^`{|}~])\s*#' => '$1', // Remove spaces following and preceeding JS-wise non-special & non-word characters + '#\s*([!\#%&()*+,\-./:;<=>?@\[\]^`{|}~])\s*#' => '$1', // Remove spaces following and preceeding JS-wise non-special & non-word characters '#\s{2,}#' => ' ' // Reduce the remaining multiple whitespace characters to a single space ); } @@ -877,7 +877,7 @@ class CI_Output { $patterns = array( '#/\*.*(?=\*/)\*/#s' => '', // Remove /* block comments */ '#\n?//[^\n]*#' => '', // Remove // line comments - '#\s*([^\w.#%)\s*#U' => '$1', // Remove spaces following and preceeding non-word characters, excluding dots, hashes and the percent sign + '#\s*([^\w.\#%])\s*#U' => '$1', // Remove spaces following and preceeding non-word characters, excluding dots, hashes and the percent sign '#\s{2,}#' => ' ' // Reduce the remaining multiple space characters to a single space ); } -- cgit v1.2.3-24-g4f1b