commit | 9f690f190f1aa503dfc6270e3a97d96196ae3cff | [log] [tgz] |
---|---|---|
author | Andrey Andreev <narf@bofh.bg> | Mon Jan 21 15:30:25 2013 +0200 |
committer | Andrey Andreev <narf@bofh.bg> | Mon Jan 21 15:30:25 2013 +0200 |
tree | 10008234cd8db0ac53cf4c92fba09f75f678a1fa | |
parent | 3ffce987e0d7efa68bbce2d83915b06e97bd3475 [diff] [blame] |
Partially implement PR #2155
diff --git a/system/core/Log.php b/system/core/Log.php index 9dabfe6..cd3c17e 100644 --- a/system/core/Log.php +++ b/system/core/Log.php
@@ -97,6 +97,8 @@ $this->_log_path = ($config['log_path'] !== '') ? $config['log_path'] : APPPATH.'logs/'; + file_exists($this->_log_path) OR mkdir($this->_log_path, DIR_WRITE_MODE, TRUE); + if ( ! is_dir($this->_log_path) OR ! is_really_writable($this->_log_path)) { $this->_enabled = FALSE;