diff options
author | Stanislav Malyshev <stas@php.net> | 2005-05-22 11:10:38 +0000 |
---|---|---|
committer | Stanislav Malyshev <stas@php.net> | 2005-05-22 11:10:38 +0000 |
commit | 6ba1dd9cbcbb478bc09ad50953988ca800ea2bca (patch) | |
tree | bc773d294cb9919a0f8c08676941e0f7d40f5797 /Zend | |
parent | a8a305966c8fb4a18ca83c13a3bff4154413ec0c (diff) | |
download | php-git-6ba1dd9cbcbb478bc09ad50953988ca800ea2bca.tar.gz |
fix leak
Diffstat (limited to 'Zend')
-rw-r--r-- | Zend/zend.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Zend/zend.c b/Zend/zend.c index daab8eec03..f95d240170 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -1003,8 +1003,11 @@ ZEND_API void zend_error(int type, const char *format, ...) zval_ptr_dtor(&z_error_type); zval_ptr_dtor(&z_error_filename); zval_ptr_dtor(&z_error_lineno); - if (ZVAL_REFCOUNT(z_context) == 2) { + if (ZVAL_REFCOUNT(z_context) <= 2) { FREE_ZVAL(z_context); + } else { + ZVAL_DELREF(z_context); + zval_ptr_dtor(&z_context); } break; } |