From f163a4d16b5c9ec67d617e8ed87967d512fbcc59 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Fri, 24 Jan 2003 16:34:20 +0000 Subject: [PATCH] Fixed a memory leak. zend_error -> php_error_docref. --- ext/yp/yp.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ext/yp/yp.c b/ext/yp/yp.c index 136ad6b98c..7fda2f0e04 100644 --- a/ext/yp/yp.c +++ b/ext/yp/yp.c @@ -241,7 +241,11 @@ static int php_foreach_all (int instatus, char *inkey, int inkeylen, char *inval if(call_user_function_ex(CG(function_table), NULL, *((zval **)indata), &retval, 3, args, 0, NULL TSRMLS_CC) != SUCCESS) { - zend_error(E_ERROR, "Function call failed"); + zval_ptr_dtor(&status); + zval_ptr_dtor(&key); + zval_ptr_dtor(&value); + + php_error_docref(NULL TSRMLS_CC, E_ERROR, "Function call failed"); return 1; } -- 2.50.1