Another way to fix this.

Signed-off-by: allexzander <blackslayer4@gmail.com>
This commit is contained in:
allexzander 2021-03-31 17:19:01 +03:00 committed by allexzander (Rebase PR Action)
parent 7235c708dc
commit 3906ae0922
3 changed files with 9 additions and 9 deletions

View file

@ -510,11 +510,13 @@ void ProcessDirectoryJob::processFileAnalyzeRemoteInfo(
&& item->_type == ItemTypeFile && item->_type == ItemTypeFile
&& opts._vfs->mode() != Vfs::Off && opts._vfs->mode() != Vfs::Off
&& _pinState != PinState::AlwaysLocal && _pinState != PinState::AlwaysLocal
#ifdef Q_OS_WIN
&& !FileSystem::isLnkFile(path._server)
#endif
) { ) {
item->_type = ItemTypeVirtualFile; item->_type = ItemTypeVirtualFile;
#ifdef Q_OS_WIN
if(FileSystem::isLnkFile(path._server)) {
item->_type = ItemTypeVirtualFileDownload;
}
#endif
if (isVfsWithSuffix()) if (isVfsWithSuffix())
addVirtualFileSuffix(tmp_path._original); addVirtualFileSuffix(tmp_path._original);
} }

View file

@ -345,11 +345,7 @@ void OCC::SyncEngine::slotItemDiscovered(const OCC::SyncFileItemPtr &item)
rec._serverHasIgnoredFiles |= prev._serverHasIgnoredFiles; rec._serverHasIgnoredFiles |= prev._serverHasIgnoredFiles;
// Ensure it's a placeholder file on disk // Ensure it's a placeholder file on disk
if (item->_type == ItemTypeFile if (item->_type == ItemTypeFile) {
#ifdef Q_OS_WIN
&& !FileSystem::isLnkFile(filePath)
#endif
) {
const auto result = _syncOptions._vfs->convertToPlaceholder(filePath, *item); const auto result = _syncOptions._vfs->convertToPlaceholder(filePath, *item);
if (!result) { if (!result) {
item->_instruction = CSYNC_INSTRUCTION_ERROR; item->_instruction = CSYNC_INSTRUCTION_ERROR;

View file

@ -196,7 +196,9 @@ bool VfsCfApi::statTypeVirtualFile(csync_file_stat_t *stat, void *statData)
stat->type = ItemTypeVirtualFileDownload; stat->type = ItemTypeVirtualFileDownload;
return true; return true;
} else if (!isSparseFile && isUnpinned){ } else if (!isSparseFile && isUnpinned){
if (!FileSystem::isLnkFile(stat->path)) {
stat->type = ItemTypeVirtualFileDehydration; stat->type = ItemTypeVirtualFileDehydration;
}
return true; return true;
} else if (isSparseFile) { } else if (isSparseFile) {
stat->type = ItemTypeVirtualFile; stat->type = ItemTypeVirtualFile;