summaryrefslogtreecommitdiff
path: root/lib/exe
diff options
context:
space:
mode:
Diffstat (limited to 'lib/exe')
-rw-r--r--lib/exe/fetch.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/exe/fetch.php b/lib/exe/fetch.php
index 384ff2d32..812850267 100644
--- a/lib/exe/fetch.php
+++ b/lib/exe/fetch.php
@@ -85,7 +85,12 @@
$fp = @fopen($FILE,"rb");
if($fp){
- fpassthru($fp); //does a close itself
+ while (!feof($fp)) {
+ @set_time_limit(); // large files can take a lot of time
+ print fread($fp, 16*1024);
+ flush();
+ }
+ fclose($fp);
}else{
header("HTTP/1.0 500 Internal Server Error");
print "Could not read $FILE - bad permissions?";