diff options
author | Eric Barnes <eric@ericlbarnes.com> | 2011-12-04 16:32:25 +0100 |
---|---|---|
committer | Eric Barnes <eric@ericlbarnes.com> | 2011-12-04 16:32:25 +0100 |
commit | 4d80234553724bad2e028ee2363d46273e6cb120 (patch) | |
tree | cfca4a13937037f7f3db05734220951751522c55 /system | |
parent | 180046646700ad869b8f8b8798321b4f8e4105c6 (diff) | |
parent | 2835e08ac46ab5c260978a2013ba8837222318c5 (diff) |
Merge pull request #739 from jeroenvdgulik/feature/logger-chmod-bug
- Stop logger from trying to chmod on each event
Diffstat (limited to 'system')
-rw-r--r-- | system/libraries/Log.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/system/libraries/Log.php b/system/libraries/Log.php index 6ea905f73..46c5b6ed2 100644 --- a/system/libraries/Log.php +++ b/system/libraries/Log.php @@ -111,6 +111,7 @@ class CI_Log { if ( ! file_exists($filepath)) { + $newfile = TRUE; $message .= "<"."?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); ?".">\n\n"; } @@ -126,7 +127,10 @@ class CI_Log { flock($fp, LOCK_UN); fclose($fp); - @chmod($filepath, FILE_WRITE_MODE); + if (isset($newfile) AND $newfile === TRUE) + { + @chmod($filepath, FILE_WRITE_MODE); + } return TRUE; } @@ -134,4 +138,4 @@ class CI_Log { // END Log Class /* End of file Log.php */ -/* Location: ./system/libraries/Log.php */
\ No newline at end of file +/* Location: ./system/libraries/Log.php */ |