From 80bf451b34089144397f82a84221ef023a0a71c9 Mon Sep 17 00:00:00 2001 From: Matthieu Gallien Date: Tue, 30 Apr 2024 13:33:58 +0200 Subject: [PATCH] as a last resort, try to update VFS metadata of folders when discovered when doing local discovery, it is possible that files or folders may be discovered with VFS metadata not up to date (i.e. placeholder file not set in sync) in such case, generate a propagation instruction to set them in sync Signed-off-by: Matthieu Gallien --- src/libsync/discovery.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libsync/discovery.cpp b/src/libsync/discovery.cpp index ba24802cf2756..86584ee388134 100644 --- a/src/libsync/discovery.cpp +++ b/src/libsync/discovery.cpp @@ -1717,7 +1717,7 @@ void ProcessDirectoryJob::processFileFinalize( } if (_discoveryData->_syncOptions._vfs && - item->_type == CSyncEnums::ItemTypeFile && + (item->_type == CSyncEnums::ItemTypeFile || item->_type == CSyncEnums::ItemTypeDirectory) && item->_instruction == CSyncEnums::CSYNC_INSTRUCTION_NONE && !_discoveryData->_syncOptions._vfs->isPlaceHolderInSync(_discoveryData->_localDir + path._local)) { item->_instruction = CSyncEnums::CSYNC_INSTRUCTION_UPDATE_VFS_METADATA;