summaryrefslogtreecommitdiffstats
path: root/system/core/URI.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2014-01-15 17:37:01 +0100
committerAndrey Andreev <narf@devilix.net>2014-01-15 17:37:01 +0100
commit08fef7de41cb06785cdb1024769892d9510e6e6b (patch)
treea261799206ceb67124896c11b4b61b13eb726a83 /system/core/URI.php
parentd8b1ad31cf7ee205ddf3cf396b1d1bfa45af49fa (diff)
Fix #2799 by adding conditional PCRE UTF-8 support to CI_URI::filter_uri()
Also did a tiny micro-optimization in the Utf8 class.
Diffstat (limited to 'system/core/URI.php')
-rw-r--r--system/core/URI.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/system/core/URI.php b/system/core/URI.php
index 3d6d202c0..c83b7a74f 100644
--- a/system/core/URI.php
+++ b/system/core/URI.php
@@ -320,7 +320,7 @@ class CI_URI {
*/
public function filter_uri($str)
{
- if ( ! empty($str) && ! empty($this->_permitted_uri_chars) && ! preg_match('/^['.$this->_permitted_uri_chars.']+$/i', $str))
+ if ( ! empty($str) && ! empty($this->_permitted_uri_chars) && ! preg_match('/^['.$this->_permitted_uri_chars.']+$/i'.(UTF8_ENABLED ? 'u' : ''), $str))
{
show_error('The URI you submitted has disallowed characters.', 400);
}