One byte placeholders assumption only holds for the suffix backend

Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
This commit is contained in:
Kevin Ottens 2020-12-18 12:16:39 +01:00
parent 4d4b87c9c3
commit 216b251b40
No known key found for this signature in database
GPG key ID: 074BBBCB8DECC9E2

View file

@ -860,8 +860,8 @@ void ProcessDirectoryJob::processFileAnalyzeLocalInfo(
auto postProcessLocalNew = [item, localEntry, this]() {
if (localEntry.isVirtualFile) {
// Remove the spurious file if it looks like a placeholder file
// (we know placeholder files contain " ")
if (localEntry.size <= 1) {
// (we know placeholder files contain " ", but only in the suffix case)
if (localEntry.size <= 1 || !isVfsWithSuffix()) {
qCWarning(lcDisco) << "Wiping virtual file without db entry for" << _currentFolder._local + "/" + localEntry.name;
item->_instruction = CSYNC_INSTRUCTION_REMOVE;
item->_direction = SyncFileItem::Down;