Commit c09c2e98b37 for php.net

commit c09c2e98b374a78a126d1dc39057ab2ab3538e9b
Merge: c98e10797b2 a1851722b86
Author: David Carlier <devnexen@gmail.com>
Date:   Sun Aug 30 15:27:14 2026 +0100

    Merge branch 'PHP-8.5'

    * PHP-8.5:
      ext/zip: php_zip_ops_stat() succeeds when the archive cannot be opened.
      ext/zip: ZipArchive::getNameIndex() index truncated to int.

diff --cc ext/zip/zip_stream.c
index a6665630e35,b70b82a415e..429342b36e3
--- a/ext/zip/zip_stream.c
+++ b/ext/zip/zip_stream.c
@@@ -192,8 -195,11 +192,11 @@@ static int php_zip_ops_stat(php_stream
  		ssb->sb.st_blocks = -1;
  #endif
  		ssb->sb.st_ino = -1;
+ 	} else {
+ 		zend_string_release_ex(file_basename, 0);
+ 		return -1;
  	}
 -	zend_string_release_ex(file_basename, 0);
 +	zend_string_release_ex(file_basename, false);
  	return 0;
  }
  /* }}} */