From f8b2b954084c247d2edd70b56b17238fe7a8024e Mon Sep 17 00:00:00 2001 From: Vincent Petry Date: Tue, 3 May 2016 16:41:54 +0200 Subject: [PATCH] Scanner must normalize new children names for cache diff Since new children from the storage might contain NFD entries, these must be normalized to NFC to be properly diff'ed with the cache contents which is always NFC. This fixes an issue where NFD entries would disappear from the cache after rescannng for children. --- lib/private/Files/Cache/Scanner.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/private/Files/Cache/Scanner.php b/lib/private/Files/Cache/Scanner.php index 03aca1924b0..3191ba15ed9 100644 --- a/lib/private/Files/Cache/Scanner.php +++ b/lib/private/Files/Cache/Scanner.php @@ -341,7 +341,7 @@ class Scanner extends BasicEmitter implements IScanner { if (is_resource($dh)) { while (($file = readdir($dh)) !== false) { if (!Filesystem::isIgnoredDir($file)) { - $children[] = $file; + $children[] = trim(\OC\Files\Filesystem::normalizePath($file), '/'); } } }