]> source.dussan.org Git - nextcloud-server.git/commitdiff
Only clear the realpath cache 21677/head
authorJ0WI <J0WI@users.noreply.github.com>
Fri, 3 Jul 2020 20:44:31 +0000 (22:44 +0200)
committerJ0WI <J0WI@users.noreply.github.com>
Fri, 3 Jul 2020 20:47:13 +0000 (22:47 +0200)
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
lib/private/Files/Storage/Local.php

index a8fa32f608e7b07452f96d4738c809944f63d78c..6d350512b221bc5d1ad5ea52c8a1da7deb40d1a4 100644 (file)
@@ -142,8 +142,8 @@ class Local extends \OC\Files\Storage\Common {
        }
 
        public function stat($path) {
-               clearstatcache();
                $fullPath = $this->getSourcePath($path);
+               clearstatcache(true, $fullPath);
                $statResult = stat($fullPath);
                if (PHP_INT_SIZE === 4 && !$this->is_dir($path)) {
                        $filesize = $this->filesize($path);
@@ -158,7 +158,7 @@ class Local extends \OC\Files\Storage\Common {
         */
        public function getMetaData($path) {
                $fullPath = $this->getSourcePath($path);
-               clearstatcache();
+               clearstatcache(true, $fullPath);
                $stat = @stat($fullPath);
                if (!$stat) {
                        return null;