summaryrefslogtreecommitdiffstats
path: root/system/core/Output.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2013-10-30 22:07:23 +0100
committerAndrey Andreev <narf@devilix.net>2013-10-30 22:07:23 +0100
commit99f9b9a70a153c93705033b5be81d5d666468675 (patch)
treec4a6bb5895db091d64fa33d80425cacc8195326f /system/core/Output.php
parentac4d30862241c61637b2138fa97da131e5b07c1f (diff)
Escape PCRE delimiters
Diffstat (limited to 'system/core/Output.php')
-rw-r--r--system/core/Output.php4
1 files 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
);
}