summaryrefslogtreecommitdiff
path: root/ext/dom/php_dom.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/dom/php_dom.c')
-rw-r--r--ext/dom/php_dom.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c
index 8fdf6aa6e0..109f7c127a 100644
--- a/ext/dom/php_dom.c
+++ b/ext/dom/php_dom.c
@@ -1075,7 +1075,7 @@ void dom_namednode_iter(dom_object *basenode, int ntype, dom_object *intern, xml
static dom_object* dom_objects_set_class(zend_class_entry *class_type, zend_bool hash_copy) /* {{{ */
{
- dom_object *intern = ecalloc(1, sizeof(dom_object) + zend_object_properties_size(class_type));
+ dom_object *intern = zend_object_alloc(sizeof(dom_object), class_type);
zend_class_entry *base_class = class_type;
while ((base_class->type != ZEND_INTERNAL_CLASS || base_class->info.internal.module->module_number != dom_module_entry.module_number) && base_class->parent != NULL) {
@@ -1106,7 +1106,7 @@ zend_object *dom_objects_new(zend_class_entry *class_type)
/* {{{ zend_object dom_xpath_objects_new(zend_class_entry *class_type) */
zend_object *dom_xpath_objects_new(zend_class_entry *class_type)
{
- dom_xpath_object *intern = ecalloc(1, sizeof(dom_xpath_object) + zend_object_properties_size(class_type));
+ dom_xpath_object *intern = zend_object_alloc(sizeof(dom_xpath_object), class_type);
intern->registered_phpfunctions = zend_new_array(0);