diff options
Diffstat (limited to 'Zend/zend_stack.c')
| -rw-r--r-- | Zend/zend_stack.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/Zend/zend_stack.c b/Zend/zend_stack.c index 266faae362..1c6b066507 100644 --- a/Zend/zend_stack.c +++ b/Zend/zend_stack.c @@ -25,13 +25,9 @@ ZEND_API int zend_stack_init(zend_stack *stack) { stack->top = 0; - stack->elements = (void **) emalloc(sizeof(void **) * STACK_BLOCK_SIZE); - if (!stack->elements) { - return FAILURE; - } else { - stack->max = STACK_BLOCK_SIZE; - return SUCCESS; - } + stack->max = 0; + stack->elements = NULL; + return SUCCESS; } ZEND_API int zend_stack_push(zend_stack *stack, const void *element, int size) |
