Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/cache/file.php')
-rw-r--r--lib/private/cache/file.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/private/cache/file.php b/lib/private/cache/file.php
index 3b500c4e45b..4624d3b2029 100644
--- a/lib/private/cache/file.php
+++ b/lib/private/cache/file.php
@@ -118,7 +118,9 @@ class File {
public function gc() {
$storage = $this->getStorage();
if($storage and $storage->is_dir('/')) {
- $now = time();
+ // extra hour safety, in case of stray part chunks that take longer to write,
+ // because touch() is only called after the chunk was finished
+ $now = time() - 3600;
$dh=$storage->opendir('/');
if(!is_resource($dh)) {
return null;