Skip to content
Snippets Groups Projects
Commit 39cbdca4 authored by Vincent Petry's avatar Vincent Petry
Browse files

Fixed path normalization to prevent dot dirs

Fixes #5945 where stat(.) would cause the backend OC to cache a dot dir
(only in older versions)
parent a20c6049
No related branches found
No related tags found
No related merge requests found
...@@ -323,11 +323,9 @@ class DAV extends \OC\Files\Storage\Common{ ...@@ -323,11 +323,9 @@ class DAV extends \OC\Files\Storage\Common{
} }
public function cleanPath($path) { public function cleanPath($path) {
if ( ! $path || $path[0]=='/') { $path = \OC\Files\Filesystem::normalizePath($path);
// remove leading slash
return substr($path, 1); return substr($path, 1);
} else {
return $path;
}
} }
private function simpleResponse($method, $path, $body, $expected) { private function simpleResponse($method, $path, $body, $expected) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment