Thank you!
On Wed, Aug 26, 2020 at 11:00 AM Alex wrote:
> Dear Ivan,
>
> Some suggestions:
>
> - Build your own copy of the PHP embed library using ./configure
> --enable-embed=shared or ./configure --enable-embed=static. Link against
> that.
> - If it doesn't work, get some already-working samp
Dear Ivan,
Some suggestions:
- Build your own copy of the PHP embed library using ./configure
--enable-embed=shared or ./configure --enable-embed=static. Link against
that.
- If it doesn't work, get some already-working sample code for use of the
PHP embed SAPI and modify it rather than starting
Yes, it does.
I recompiled php now with
--configure --enable-embed=static
and wrote a simple script:
#include
#include
#include "sapi/embed/php_embed.h"
int main(int argc, char *argv[]) {
php_embed_init(argc, argv);
HashTable *ht = zend_new_array(15);
return 0;
}
On Tue, Aug 25, 2020 at 5:31 AM Ivan Zanev wrote:
>
> Hello,
>
> I'm trying to learn a bit more about HashTable in PHP internally and how
> memory is allocated when generating arrays with various sizes. I created a
> simple C script that would call
>
> HashTable *ht = zend_new_array(15);
>
> Howev
Hello,
I'm trying to learn a bit more about HashTable in PHP internally and how
memory is allocated when generating arrays with various sizes. I created a
simple C script that would call
HashTable *ht = zend_new_array(15);
However, when I compile the script with gcc, I get segmentation fault; gd