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)
This commit is contained in:
Vincent Petry 2013-11-20 18:14:42 +01:00
parent a20c6049c3
commit 39cbdca429

View file

@ -323,11 +323,9 @@ class DAV extends \OC\Files\Storage\Common{
}
public function cleanPath($path) {
if ( ! $path || $path[0]=='/') {
return substr($path, 1);
} else {
return $path;
}
$path = \OC\Files\Filesystem::normalizePath($path);
// remove leading slash
return substr($path, 1);
}
private function simpleResponse($method, $path, $body, $expected) {