1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

ext/gmp: use zend_object_alloc instead to initialize GMP instances. (#17822)

This commit is contained in:
David CARLIER
2025-02-15 19:09:36 +00:00
committed by GitHub
parent ed9c283589
commit 05a155782b

View File

@@ -208,7 +208,7 @@ static void gmp_free_object_storage(zend_object *obj) /* {{{ */
static inline zend_object *gmp_create_object_ex(zend_class_entry *ce, mpz_ptr *gmpnum_target) /* {{{ */
{
gmp_object *intern = emalloc(sizeof(gmp_object) + zend_object_properties_size(ce));
gmp_object *intern = zend_object_alloc(sizeof(gmp_object), ce);
zend_object_std_init(&intern->std, ce);
object_properties_init(&intern->std, ce);