mirror of
https://github.com/filegator/filegator.git
synced 2025-08-01 00:20:16 +02:00
feof checks
This commit is contained in:
@@ -107,12 +107,14 @@ class DownloadController
|
||||
// @codeCoverageIgnoreStart
|
||||
set_time_limit(0);
|
||||
$file = $tmpfs->readStream($uniqid);
|
||||
while ($file && ! feof($file['stream'])) {
|
||||
echo fread($file['stream'], 1024 * 8);
|
||||
ob_flush();
|
||||
flush();
|
||||
if ($file['stream']) {
|
||||
while (! feof($file['stream'])) {
|
||||
echo fread($file['stream'], 1024 * 8);
|
||||
ob_flush();
|
||||
flush();
|
||||
}
|
||||
fclose($file['stream']);
|
||||
}
|
||||
fclose($file['stream']);
|
||||
$tmpfs->remove($uniqid);
|
||||
// @codeCoverageIgnoreEnd
|
||||
});
|
||||
|
Reference in New Issue
Block a user