Author: dr Date: Wed Feb 6 14:09:47 2008 New Revision: 7310 Log: - Fixed file pointer caching, that was broken by the last commit.
Modified: trunk/EventLog/src/writers/writer_file.php trunk/EventLog/tests/writers/temp_implementation.php Modified: trunk/EventLog/src/writers/writer_file.php ============================================================================== --- trunk/EventLog/src/writers/writer_file.php [iso-8859-1] (original) +++ trunk/EventLog/src/writers/writer_file.php [iso-8859-1] Wed Feb 6 14:09:47 2008 @@ -168,7 +168,8 @@ { if ( !is_null( $this->defaultFile ) ) { - if ( fwrite( $this->openFiles[$this->defaultFile], $string ) === false ) + $path = $this->logDirectory . "/". $this->defaultFile; + if ( fwrite( $this->openFiles[$path], $string ) === false ) { throw new ezcLogWriterException( new ezcBaseFileIoException( $this->defaultFile, ezcBaseFileIoException::WRITE ) ); } @@ -211,7 +212,7 @@ } } - $this->openFiles[$fileName] = $fh; + $this->openFiles[$path] = $fh; return $fh; } Modified: trunk/EventLog/tests/writers/temp_implementation.php ============================================================================== --- trunk/EventLog/tests/writers/temp_implementation.php [iso-8859-1] (original) +++ trunk/EventLog/tests/writers/temp_implementation.php [iso-8859-1] Wed Feb 6 14:09:47 2008 @@ -26,5 +26,11 @@ $res = print_r( array( "message" => $message, "type" => $type, "source" => $source, "category" => $category ), true ); $this->write( $type, $source, $category, $res ); } + + public function openFile( $fileName ) + { + return parent::openFile( $fileName ); + } + } ?> -- svn-components mailing list svn-components@lists.ez.no http://lists.ez.no/mailman/listinfo/svn-components