Make encrypted folder paths to delete non-relative when checking if they are encrypted
authorClaudio Cambra <claudio.cambra@nextcloud.com>
Mon, 23 Jan 2023 20:36:48 +0000 (21:36 +0100)
committerClaudio Cambra <claudio.cambra@nextcloud.com>
Tue, 24 Jan 2023 16:00:16 +0000 (17:00 +0100)
Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
src/gui/folder.cpp

index 62156a7f03183909c77e4607b64700adc27fe14a..05f61d6b809da550cee05d385cb560bcdd52dad2 100644 (file)
@@ -1341,7 +1341,7 @@ void Folder::removeLocalE2eFiles()
     const auto couldGetFiles = _journal.getFilesBelowPath("", [this, &e2eFoldersToBlacklist, &folderRootDir](const SyncJournalFileRecord &rec) {
         // We only want to add the root-most encrypted folder to the blacklist
         if (rec.isValid() && rec._isE2eEncrypted && rec.isDirectory()) {
-            QDir pathDir(rec._path);
+            QDir pathDir(_canonicalLocalPath + rec.path());
             bool parentPathEncrypted = false;
 
             while (pathDir.cdUp() && pathDir != folderRootDir) {