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
path: root/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2020-05-22 10:21:53 +0300
committerRoeland Jago Douma <roeland@famdouma.nl>2020-05-22 10:21:53 +0300
commit6b2674478770e1b09aedc4e32613a4e01f9075b9 (patch)
tree1d4a1ef90647adc221e866743f5e17a8ba449aa8 /lib
parent0a45f44bebb10d01d4f8140830b6b186199d56ba (diff)
Clear the statscache before fetching the metadata
Else if a lot of writes happen. It might happen that an old stat result is used. Resulting in a wrong file size for the file. For example the text app when a lot of people edit at the same time. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Files/Storage/Local.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php
index 6da019178c0..4cf3ac4799f 100644
--- a/lib/private/Files/Storage/Local.php
+++ b/lib/private/Files/Storage/Local.php
@@ -156,6 +156,7 @@ class Local extends \OC\Files\Storage\Common {
*/
public function getMetaData($path) {
$fullPath = $this->getSourcePath($path);
+ clearstatcache();
$stat = @stat($fullPath);
if (!$stat) {
return null;