mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Merge branch 'PHP-8.5'
* PHP-8.5: phar: Fix file descriptor leak in phar_zip_flush() on failure.
This commit is contained in:
@@ -1259,6 +1259,7 @@ ZEND_ATTRIBUTE_NONNULL_ARGS(1, 4) void phar_zip_flush(phar_archive_data *phar, z
|
||||
return;
|
||||
}
|
||||
if (phar->alias_len != php_stream_write(entry.fp, phar->alias, phar->alias_len)) {
|
||||
php_stream_close(entry.fp);
|
||||
spprintf(error, 0, "unable to set alias in zip-based phar \"%s\"", phar->fname);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user