cvs: ZendEngine2 / zend_builtin_functions.c
| From: | Stanislav Malyshev | Date: | Thu, 03 Jul 2003 08:00:10 +0000 |
| Subject: | cvs: ZendEngine2 / zend_builtin_functions.c | ||
| Groups: | php.zend-engine.cvs | ||
| Request: | Send a blank email to php-zend-engine-cvs+get-1448@lists.php.net to get a copy of this message | ||
stas Thu Jul 3 04:00:10 2003 EDT
Modified files:
/ZendEngine2 zend_builtin_functions.c
Log:
fix the get_parent_class fix
Index: ZendEngine2/zend_builtin_functions.c
diff -u ZendEngine2/zend_builtin_functions.c:1.199 ZendEngine2/zend_builtin_functions.c:1.200
--- ZendEngine2/zend_builtin_functions.c:1.199 Wed Jul 2 17:57:57 2003
+++ ZendEngine2/zend_builtin_functions.c Thu Jul 3 04:00:10 2003
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_builtin_functions.c,v 1.199 2003/07/02 21:57:57 helly Exp $ */
+/* $Id: zend_builtin_functions.c,v 1.200 2003/07/03 08:00:10 stas Exp $ */
#include "zend.h"
#include "zend_API.h"
@@ -557,7 +557,12 @@
}
if (Z_TYPE_PP(arg) == IS_OBJECT) {
- ce = zend_get_class_entry(*arg TSRMLS_CC);
+ if (Z_OBJ_HT_PP(arg)->get_class_name
+ && Z_OBJ_HT_PP(arg)->get_class_name(*arg, &name, &name_length, 1 TSRMLS_CC)
== SUCCESS) {
+ RETURN_STRINGL(name, name_length, 0);
+ } else {
+ ce = zend_get_class_entry(*arg TSRMLS_CC);
+ }
} else if (Z_TYPE_PP(arg) == IS_STRING) {
zend_class_entry **pce;
@@ -615,7 +620,7 @@
if (!instance_ce) {
efree(lcname);
RETURN_FALSE;
- }
+ }
if (instanceof_function(instance_ce, *ce TSRMLS_CC)) {
retval = 1;