Re: problem with zend_register_internal_class

From: Date: Mon, 16 Jan 2006 14:19:41 +0000
Subject: Re: problem with zend_register_internal_class
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-21557@lists.php.net to get a copy of this message
You forgot to add TSRMLS_CC macro: zend_register_internal_class(&ce TSRMLS_CC); Btw, pecl-dev@lists.php.net is more appropriate list for such questions. On 16.01.2006 02:01, Jan Pieper wrote:
If I compile my class if written, I get this error-messages: ~/php-5.1.1/ext/smartflow/smartflow.c: In function 'zm_startup_smartflow': ~/php-5.1.1/ext/smartflow/smartflow.c:109: error: too few arguments to function 'zend_register_internal_class' make: *** [ext/smartflow/smartflow.lo] Fehler 1 These are the lines where I get this error-messages (smartflow.c/lines: 91-110): PHP_MINIT_FUNCTION(smartflow) {
         zend_class_entry smartflow_ce;
         INIT_CLASS_ENTRY(
                 smartflow,
                 "SmartFlow",
                 smartflow_methods
         );
         smartflow_ce_ptr = zend_register_internal_class(&smartflow_ce); // 101
         zend_declare_property_string(
                 smartflow_ce_ptr, // 104
                 "content", strlen("content"), "",
                 ZEND_ACC_PUBLIC
         );
         return SUCCESS;
} I have another class with "exactly the same" lines but there I get no error-messages. I can´t find any differences in my sources. I hope you can help me to fix my problem. If I add TSRMLS_CC to line 101 and 104 I don´t get these error-messages but after compiling php I get a memory-access error. - Jan Pieper
-- Wbr, Antony Dovgal

« previous php.internals (#21557) next »