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:
authorblizzz <blizzz@arthur-schiwon.de>2022-04-22 12:38:04 +0300
committerGitHub <noreply@github.com>2022-04-22 12:38:04 +0300
commitb9bfd5aba8f994d13720307a0a46e76d32184e02 (patch)
tree2da21ffbd636050559c8ae3b31e0d599c8c923e3 /lib
parentfdaf6d0db2965190c080aa56bf8213dd5dceed39 (diff)
parent29dc5c8cb5c7498817b85f1655e91894ab3d8555 (diff)
Merge pull request #32027 from nextcloud/backport/32024/stable24
[stable24] ignore forbidden files while scanning local storage
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Files/Storage/Local.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php
index 34ab9a5fc97..d637b3d194f 100644
--- a/lib/private/Files/Storage/Local.php
+++ b/lib/private/Files/Storage/Local.php
@@ -173,7 +173,11 @@ class Local extends \OC\Files\Storage\Common {
* @inheritdoc
*/
public function getMetaData($path) {
- $stat = $this->stat($path);
+ try {
+ $stat = $this->stat($path);
+ } catch (ForbiddenException $e) {
+ return null;
+ }
if (!$stat) {
return null;
}