File tree 1 file changed +7
-4
lines changed
1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -1004,9 +1004,12 @@ static void release_dynamic_function_entries(void) {
1004
1004
}
1005
1005
1006
1006
// workaround for https://github.com/php/php-src/issues/11883
1007
- static void release_ZendTestClass_dnf_property (void ) {
1008
- zend_property_info * prop = zend_hash_str_find_ptr (& zend_test_class -> properties_info , "dnfProperty" , sizeof ("dnfProperty" ) - 1 );
1009
- release_internal_zend_type (& prop -> type );
1007
+ static void release_ZendTestClass_dnf_property (int module_type ) {
1008
+ // zend_hash_str_find_bucket fails when the module is loaded with dl(), no idea why...
1009
+ if (module_type == MODULE_PERSISTENT ) {
1010
+ zend_property_info * prop = zend_hash_str_find_ptr (& zend_test_class -> properties_info , "dnfProperty" , sizeof ("dnfProperty" ) - 1 );
1011
+ release_internal_zend_type (& prop -> type );
1012
+ }
1010
1013
}
1011
1014
1012
1015
PHP_MINIT_FUNCTION (zend_test )
@@ -1086,7 +1089,7 @@ PHP_MINIT_FUNCTION(zend_test)
1086
1089
PHP_MSHUTDOWN_FUNCTION (zend_test )
1087
1090
{
1088
1091
release_dynamic_function_entries ();
1089
- release_ZendTestClass_dnf_property ();
1092
+ release_ZendTestClass_dnf_property (type );
1090
1093
1091
1094
if (type != MODULE_TEMPORARY ) {
1092
1095
UNREGISTER_INI_ENTRIES ();
You can’t perform that action at this time.
0 commit comments