From 7bf4fa69be02b4ae716c5277d4c65e7a4d5db250 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 9 Jun 2014 15:41:29 +0400 Subject: [PATCH] Avoid extra function call on hot path --- Zend/zend_execute.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 95028ffcee..642f1e3080 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1111,9 +1111,10 @@ fetch_from_array: long offset; if (type != BP_VAR_UNSET && UNEXPECTED(Z_STRLEN_P(container) == 0)) { -convert_to_array: zval_dtor(container); - array_init(container); +convert_to_array: + ZVAL_NEW_ARR(container); + zend_hash_init(Z_ARRVAL_P(container), 8, NULL, ZVAL_PTR_DTOR, 0); goto fetch_from_array; } if (dim == NULL) { -- 2.50.1