The zend_register_list_destructors_ex API expects one function
pointer for the resource destructor, and another function pointer for
the persistent resource destructor. I missed that details, and it
explains why the destructor was never called for a persistent
resource. Now it works! No more memory leaks.
cc @nikic in case you want to know the end of the story :-).
Sequel of #33.
The
zend_register_list_destructors_ex
API expects one function pointer for the resource destructor, and another function pointer for the persistent resource destructor. I missed that details, and it explains why the destructor was never called for a persistent resource. Now it works! No more memory leaks.cc @nikic in case you want to know the end of the story :-).