cvs: ZendEngine2 / zend_execute_API.c
| From: | Stanislav Malyshev | Date: | Thu, 14 Mar 2002 12:18:01 +0000 |
| Subject: | cvs: ZendEngine2 / zend_execute_API.c | ||
| Groups: | php.zend-engine.cvs | ||
| Request: | Send a blank email to php-zend-engine-cvs+get-19@lists.php.net to get a copy of this message | ||
stas Thu Mar 14 07:18:01 2002 EDT
Modified files:
/ZendEngine2 zend_execute_API.c
Log:
Fix call_user_function
Index: ZendEngine2/zend_execute_API.c
diff -u ZendEngine2/zend_execute_API.c:1.158 ZendEngine2/zend_execute_API.c:1.159
--- ZendEngine2/zend_execute_API.c:1.158 Tue Mar 12 05:08:47 2002
+++ ZendEngine2/zend_execute_API.c Thu Mar 14 07:18:01 2002
@@ -480,16 +480,16 @@
if (object_pp) {
/* TBI!! new object handlers */
- if(!IS_ZEND_STD_OBJECT(**object_pp)) {
- zend_error(E_WARNING, "Cannot use call_user_function on overloaded objects");
- return FAILURE;
- }
-
if (Z_TYPE_PP(object_pp) == IS_OBJECT) {
+ if(!IS_ZEND_STD_OBJECT(**object_pp)) {
+ zend_error(E_WARNING, "Cannot use call_user_function on overloaded objects");
+ return FAILURE;
+ }
+
function_table = &Z_OBJCE_PP(object_pp)->function_table;
calling_scope = Z_OBJCE_PP(object_pp);
} else if (Z_TYPE_PP(object_pp) == IS_STRING) {
- zend_class_entry *ce;
+ zend_class_entry **ce;
char *lc_class;
int found;
@@ -500,8 +500,8 @@
if (found == FAILURE)
return FAILURE;
- function_table = &ce->function_table;
- calling_scope = ce;
+ function_table = &(*ce)->function_table;
+ calling_scope = *ce;
object_pp = NULL;
} else
return FAILURE;