summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXinchen Hui <laruence@php.net>2014-05-05 17:48:49 +0800
committerXinchen Hui <laruence@php.net>2014-05-05 17:48:49 +0800
commit39c521c05693f3fdac5402e05750f33c98e74e9a (patch)
tree8a98d08e3a50defed913fc52dcb6540c6cc0f7b0
parent356824df4cd26648ef3e099472d527a4e2796362 (diff)
downloadphp-git-39c521c05693f3fdac5402e05750f33c98e74e9a.tar.gz
Finish Zip (all tests pass)
-rw-r--r--ext/zip/php_zip.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c
index d73290d90f..da64cc10cd 100644
--- a/ext/zip/php_zip.c
+++ b/ext/zip/php_zip.c
@@ -2144,9 +2144,11 @@ static ZIPARCHIVE_METHOD(getExternalAttributesName)
(zip_flags_t)flags, &opsys, &attr) < 0) {
RETURN_FALSE;
}
- zval_dtor(z_opsys);
+ ZVAL_DEREF(z_opsys);
+ zval_ptr_dtor(z_opsys);
ZVAL_LONG(z_opsys, opsys);
- zval_dtor(z_attr);
+ ZVAL_DEREF(z_attr);
+ zval_ptr_dtor(z_attr);
ZVAL_LONG(z_attr, attr);
RETURN_TRUE;
}
@@ -2179,8 +2181,10 @@ static ZIPARCHIVE_METHOD(getExternalAttributesIndex)
(zip_flags_t)flags, &opsys, &attr) < 0) {
RETURN_FALSE;
}
+ ZVAL_DEREF(z_opsys);
zval_dtor(z_opsys);
ZVAL_LONG(z_opsys, opsys);
+ ZVAL_DEREF(z_attr);
zval_dtor(z_attr);
ZVAL_LONG(z_attr, attr);
RETURN_TRUE;