mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Free attribute validators on shutdown
This commit is contained in:
parent
d3eeeb6882
commit
5b4c4bbe3b
3 changed files with 8 additions and 0 deletions
|
@ -32,6 +32,7 @@
|
||||||
#include "zend_smart_str.h"
|
#include "zend_smart_str.h"
|
||||||
#include "zend_smart_string.h"
|
#include "zend_smart_string.h"
|
||||||
#include "zend_cpuinfo.h"
|
#include "zend_cpuinfo.h"
|
||||||
|
#include "zend_attributes.h"
|
||||||
|
|
||||||
static size_t global_map_ptr_last = 0;
|
static size_t global_map_ptr_last = 0;
|
||||||
|
|
||||||
|
@ -1077,6 +1078,7 @@ void zend_shutdown(void) /* {{{ */
|
||||||
zend_hash_destroy(GLOBAL_CONSTANTS_TABLE);
|
zend_hash_destroy(GLOBAL_CONSTANTS_TABLE);
|
||||||
free(GLOBAL_CONSTANTS_TABLE);
|
free(GLOBAL_CONSTANTS_TABLE);
|
||||||
zend_shutdown_strtod();
|
zend_shutdown_strtod();
|
||||||
|
zend_attributes_shutdown();
|
||||||
|
|
||||||
#ifdef ZTS
|
#ifdef ZTS
|
||||||
GLOBAL_FUNCTION_TABLE = NULL;
|
GLOBAL_FUNCTION_TABLE = NULL;
|
||||||
|
|
|
@ -144,3 +144,8 @@ void zend_register_attribute_ce(void)
|
||||||
|
|
||||||
zend_compiler_attribute_register(zend_ce_php_attribute, zend_attribute_validate_phpattribute);
|
zend_compiler_attribute_register(zend_ce_php_attribute, zend_attribute_validate_phpattribute);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void zend_attributes_shutdown(void)
|
||||||
|
{
|
||||||
|
zend_hash_destroy(&internal_validators);
|
||||||
|
}
|
||||||
|
|
|
@ -65,5 +65,6 @@ static zend_always_inline zend_attribute *zend_add_class_constant_attribute(zend
|
||||||
}
|
}
|
||||||
|
|
||||||
void zend_register_attribute_ce(void);
|
void zend_register_attribute_ce(void);
|
||||||
|
void zend_attributes_shutdown(void);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue