1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

some more fixes

git-svn-id: file:///svn/phpbb/trunk@7875 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen
2007-07-12 16:14:07 +00:00
parent 2ba03a411e
commit 002dd81557
11 changed files with 79 additions and 9 deletions

View File

@@ -322,7 +322,20 @@ function send_avatar_to_browser($file)
header("Content-Length: $size");
}
readfile($file_path);
if (@readfile($file_path) === false)
{
$fp = @fopen($file_path, 'rb');
if ($fp !== false)
{
while (!feof($fp))
{
echo fread($fp, 8192);
}
fclose($fp);
}
}
flush();
}
else
@@ -447,6 +460,10 @@ function send_file_to_browser($attachment, $upload_dir, $category)
}
fclose($fp);
}
else
{
@readfile($filename);
}
flush();
exit;