summaryrefslogtreecommitdiffstats
path: root/lib/private/Files/View.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/Files/View.php')
-rw-r--r--lib/private/Files/View.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Files/View.php b/lib/private/Files/View.php
index 1bee09e3659..ed7d6c26318 100644
--- a/lib/private/Files/View.php
+++ b/lib/private/Files/View.php
@@ -456,7 +456,7 @@ class View {
// forward file handle via chunked fread because fseek seem to have failed
$end = $from + 1;
- while (!feof($handle) && ftell($handle) < $end) {
+ while (!feof($handle) && ftell($handle) < $end && ftell($handle) !== $from) {
$len = $from - ftell($handle);
if ($len > $chunkSize) {
$len = $chunkSize;