Re: Re: Another question about storing zend_fcall_info and zend_fcall_info_cache

From: Date: Tue, 30 Jul 2013 11:03:21 +0000
Subject: Re: Re: Another question about storing zend_fcall_info and zend_fcall_info_cache
References: 1 2  Groups: php.pecl.dev 
Request: Send a blank email to pecl-dev+get-10923@lists.php.net to get a copy of this message
On Tue, 2013-07-30 at 15:37 +0500, Ruslan Osmanov wrote: > > So what is the proper way to deal with zend_fcall_info.object_ptr's > refcount? I didn't find a Zend API function to copy fcall info. > I also didn't find a way to obtain the caller's "this_ptr" pointer. > EG(This) points to current (Event) this_ptr, not Foo's this_ptr. This hit me, too. I once thought about "fixing" this in zend_parse_parameters but figured this would cause an anomaly where the caller suddenly has to free memory allocated in zpp. My solution for this is here: https://github.com/johannes/php-test-helpers/blob/master/test_helpers.c#L342 and here https://github.com/johannes/php-test-helpers/blob/master/test_helpers.c#L178 hope this helps, johannes

« previous php.pecl.dev (#10923) next »