Commit 39776508202 for php.net
commit 3977650820273ee31d488687b9b3d1bb5587f8fe
Merge: bc08fa3b95f 75cd8fbb556
Author: Niels Dossche <7771979+ndossche@users.noreply.github.com>
Date: Sun Nov 16 21:29:21 2025 +0100
Merge branch 'PHP-8.5'
* PHP-8.5:
Fix crash in property existence test in ext/zip
diff --cc ext/zip/php_zip.c
index 49506a19862,871c30dc003..b0a53dc2e66
--- a/ext/zip/php_zip.c
+++ b/ext/zip/php_zip.c
@@@ -928,17 -926,16 +928,16 @@@ static int php_zip_has_property(zend_ob
if (hnd != NULL) {
zval tmp, *prop;
-- if (type == 2) {
++ if (type == ZEND_PROPERTY_EXISTS) {
retval = true;
} else if ((prop = php_zip_property_reader(obj, hnd, &tmp)) != NULL) {
-- if (type == 1) {
++ if (type == ZEND_PROPERTY_NOT_EMPTY) {
retval = zend_is_true(&tmp);
-- } else if (type == 0) {
++ } else if (type == ZEND_PROPERTY_ISSET) {
retval = (Z_TYPE(tmp) != IS_NULL);
}
+ zval_ptr_dtor(&tmp);
}
-
- zval_ptr_dtor(&tmp);
} else {
retval = zend_std_has_property(object, name, type, cache_slot);
}