It would appear that the call_method object handler is never called.

When I call an undefined method, this is the code that is executed:

zend_vm_execute.h line 20655:

EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen TSRMLS_CC);
if (!EX(fbc)) {
zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s ()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval);
}

On Jul 2, 2005, at 2:15 AM, [EMAIL PROTECTED] wrote:

I am not sure if this is the proper list, but I need help in getting my handlers called via the zend API.

I have just begun to make an extension, and I need to make use of the call_method handler.

To see if I could hook in, I defined this:

static int call_method(char *method, INTERNAL_FUNCTION_PARAMETERS)
{
    return 0;
}

and then set the call_method handler to this with the expectation that no error would occur when an undefined method is called. However, the error remains, and it appears this function isn't even called.

Moreover, I know my handler array is correct, because I tried:

......get_method = 0;

the result of which was an error that said my object doesn't support methods.

I even tried defining get_method as follows:

static union _zend_function* get_method(zval *object, char *method, int method_len TSRMLS_DC)
{
    return NULL;
}

But that didn't help.

Any response will be appreciated.

Herr Witten

Reply via email to