> That's TSRMLS_FETCH() (you have extra S).

So now I have:

PHP_RINIT_FUNCTION(vardumpoverload)
{
    zend_function *orig_1;

    TSRMLS_FETCH();

    /* Override require_once with our own function */

    zend_hash_find(CG(function_table), "require_once", 13, (void
**)&orig_1);
    VARDUMPOVERLOAD_G(orig_require_once_func) =
orig_1->internal_function.handler;
    orig_1->internal_function.handler = zif_vardumpoverload_require_once;

    return SUCCESS;
}

and when I compile it I get the following error:

VarDumpOverloadExtension/vardumpoverload.c:66: error: 'tsrm_ls'
redeclared as different kind of symbol
VarDumpOverloadExtension/vardumpoverload.c:62: error: previous
definition of 'tsrm_ls' was here


When I don't use TSRMLS_FETCH(); at all I get a "Bus error" when running
the extension and calling require_once().

Christoph


-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to