diff options
Diffstat (limited to 'system/core/Log.php')
-rw-r--r-- | system/core/Log.php | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/system/core/Log.php b/system/core/Log.php index 4338aa939..d651e8abe 100644 --- a/system/core/Log.php +++ b/system/core/Log.php @@ -124,7 +124,9 @@ class CI_Log { isset(self::$func_overload) OR self::$func_overload = (extension_loaded('mbstring') && ini_get('mbstring.func_overload')); - $this->_log_path = ($config['log_path'] !== '') ? $config['log_path'] : APPPATH.'logs/'; + $this->_log_path = ($config['log_path'] !== '') + ? rtrim($config['log_path'], '/\\').DIRECTORY_SEPARATOR : APPPATH.'logs'.DIRECTORY_SEPARATOR; + $this->_file_ext = (isset($config['log_file_extension']) && $config['log_file_extension'] !== '') ? ltrim($config['log_file_extension'], '.') : 'php'; @@ -283,9 +285,6 @@ class CI_Log { { if (self::$func_overload) { - // mb_substr($str, $start, null, '8bit') returns an empty - // string on PHP 5.3 - isset($length) OR $length = ($start >= 0 ? self::strlen($str) - $start : -$start); return mb_substr($str, $start, $length, '8bit'); } |