diff --git a/ext/phar/zip.c b/ext/phar/zip.c index 7c564dfb455..a7f2fa0a72d 100644 --- a/ext/phar/zip.c +++ b/ext/phar/zip.c @@ -1402,6 +1402,7 @@ fperror: pass.centralfp = php_stream_fopen_tmpfile(); if (!pass.centralfp) { + php_stream_close(pass.filefp); goto fperror; }