Author: Tobias Schlitt
Date: 2006-01-26 15:55:00 +0100 (Thu, 26 Jan 2006)
New Revision: 2044
Log:
- Move sanity checks over call to realpath() in
ezcImageMethodcallHandler::loadCommon(). Makes more sense.
- Fix autoload in converter example code.
Modified:
packages/ImageConversion/trunk/src/converter.php
packages/ImageConversion/trunk/src/interfaces/methodcall_handler.php
Modified: packages/ImageConversion/trunk/src/converter.php
===================================================================
--- packages/ImageConversion/trunk/src/converter.php 2006-01-26 14:52:37 UTC
(rev 2043)
+++ packages/ImageConversion/trunk/src/converter.php 2006-01-26 14:55:00 UTC
(rev 2044)
@@ -20,17 +20,6 @@
* // ezc autoloading facility
* function __autoload( $class_name )
* {
- * require_once("Base/trunk/src/base.php");
- * if ( strpos( $class_name, "_" ) !== false )
- * {
- * $file = str_replace( "_", "/", $class_name ) . ".php";
- * $val = require_once( $file );
- * if ( $val == 0 )
- * {
- * return true;
- * }
- * return false;
- * }
* ezcBase::autoload( $class_name );
* }
*
Modified: packages/ImageConversion/trunk/src/interfaces/methodcall_handler.php
===================================================================
--- packages/ImageConversion/trunk/src/interfaces/methodcall_handler.php
2006-01-26 14:52:37 UTC (rev 2043)
+++ packages/ImageConversion/trunk/src/interfaces/methodcall_handler.php
2006-01-26 14:55:00 UTC (rev 2044)
@@ -446,9 +446,6 @@
*/
protected function loadCommon( $file, $mime = null )
{
- $file = realpath( $file );
- $ref = md5( $file );
-
if ( !is_file( $file ) )
{
throw new ezcBaseFileNotFoundException( $file );
@@ -457,6 +454,10 @@
{
throw new ezcBaseFilePermissionException( $file,
ezcBaseFileException::READ );
}
+
+ $file = realpath( $file );
+ $ref = md5( $file );
+
if ( !isset( $mime ) )
{
$mime = '';
--
svn-components mailing list
[email protected]
http://lists.ez.no/mailman/listinfo/svn-components