diff options
author | Robin Appelman <robin@icewind.nl> | 2021-01-06 17:25:31 +0100 |
---|---|---|
committer | Robin Appelman <robin@icewind.nl> | 2021-01-06 17:27:31 +0100 |
commit | 205386b24e0b16a8cce9db9b00e296fb813ffc7f (patch) | |
tree | 11e1341f130436ff762e3ceacf83859ce0faaac6 /lib | |
parent | 9b9c1aa7fd643747cd423d40c9c82ffa74e9e452 (diff) | |
download | nextcloud-server-205386b24e0b16a8cce9db9b00e296fb813ffc7f.tar.gz nextcloud-server-205386b24e0b16a8cce9db9b00e296fb813ffc7f.zip |
ignore files that have no read permissions during scanning
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/Cache/Scanner.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/private/Files/Cache/Scanner.php b/lib/private/Files/Cache/Scanner.php index 1b9637ac61e..26264321a9a 100644 --- a/lib/private/Files/Cache/Scanner.php +++ b/lib/private/Files/Cache/Scanner.php @@ -415,6 +415,10 @@ class Scanner extends BasicEmitter implements IScanner { $childQueue = []; $newChildNames = []; foreach ($newChildren as $fileMeta) { + $permissions = isset($fileMeta['scan_permissions']) ? $fileMeta['scan_permissions'] : $fileMeta['permissions']; + if ($permissions === 0) { + continue; + } $file = $fileMeta['name']; $newChildNames[] = $file; $child = $path ? $path . '/' . $file : $file; |