diff options
Diffstat (limited to 'lib/private/files/filesystem.php')
-rw-r--r-- | lib/private/files/filesystem.php | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/private/files/filesystem.php b/lib/private/files/filesystem.php index 140d892652f..e933782ce2f 100644 --- a/lib/private/files/filesystem.php +++ b/lib/private/files/filesystem.php @@ -543,9 +543,11 @@ class Filesystem { * @return bool */ static public function isFileBlacklisted($filename) { + $filename = self::normalizePath($filename); + $blacklist = \OC_Config::getValue('blacklisted_files', array('.htaccess')); $filename = strtolower(basename($filename)); - return (in_array($filename, $blacklist)); + return in_array($filename, $blacklist); } /** @@ -734,6 +736,9 @@ class Filesystem { return '/'; } + //normalize unicode if possible + $path = \OC_Util::normalizeUnicode($path); + //no windows style slashes $path = str_replace('\\', '/', $path); @@ -770,9 +775,6 @@ class Filesystem { $path = substr($path, 0, -2); } - //normalize unicode if possible - $path = \OC_Util::normalizeUnicode($path); - $normalizedPath = $windows_drive_letter . $path; self::$normalizedPathCache[$cacheKey] = $normalizedPath; |