phar_stream_close in ext/phar/stream.c calls phar_stream_flush but discards its return value, always returning 0 (success) from fclose() even when the flush failed.
If phar_stream_flush encounters a write error (e.g. out of disk space while committing phar modifications), the application gets no indication of failure from fclose($fp).
Location: phar_stream_close — phar_stream_flush(stream); return value is silently dropped.
Fix: capture the flush return value and return it from phar_stream_close.
phar_stream_closeinext/phar/stream.ccallsphar_stream_flushbut discards its return value, always returning 0 (success) fromfclose()even when the flush failed.If
phar_stream_flushencounters a write error (e.g. out of disk space while committing phar modifications), the application gets no indication of failure fromfclose($fp).Location:
phar_stream_close—phar_stream_flush(stream);return value is silently dropped.Fix: capture the flush return value and return it from
phar_stream_close.