com php-src: Fix spl_directory cast_object, reenable error: Zend/zend_execute.h ext/spl/spl_directory .c

From: Date: Mon, 12 May 2014 18:44:30 +0000
Subject: com php-src: Fix spl_directory cast_object, reenable error: Zend/zend_execute.h ext/spl/spl_directory .c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-78290@lists.php.net to get a copy of this message
Commit: 8904f72d7c47253345f7039afd8ca754442c7e34 Author: Nikita Popov <nikic@php.net> Mon, 12 May 2014 20:44:30 +0200 Parents: f29b68306d457ebc157254a7af186e5a4fd6db80 Branches: phpng Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=8904f72d7c47253345f7039afd8ca754442c7e34 Log: Fix spl_directory cast_object, reenable error Changed paths: M Zend/zend_execute.h M ext/spl/spl_directory.c Diff: diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index 0007e98..52689d2 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -115,8 +115,7 @@ again: break; } - // TODO: The following line breakes phar ??? - // zend_error(E_RECOVERABLE_ERROR, "Object of class %s could not be converted to boolean", Z_OBJ_P(op)->ce->name->val); + zend_error(E_RECOVERABLE_ERROR, "Object of class %s could not be converted to boolean", Z_OBJ_P(op)->ce->name->val); } else if (Z_OBJ_HT_P(op)->get) { zval rv; zval *tmp = Z_OBJ_HT_P(op)->get(op, &rv TSRMLS_CC); diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 8cc7ec0..f7a1de4 100644 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -1881,6 +1881,9 @@ static int spl_filesystem_object_cast(zval *readobj, zval *writeobj, int type TS } return SUCCESS; } + } else if (type == _IS_BOOL) { + ZVAL_TRUE(writeobj); + return SUCCESS; } if (readobj == writeobj) { zval_dtor(readobj);

« previous php.cvs (#78290) next »