Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/desktop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCamila San <hello@camila.codes>2019-07-31 20:50:36 +0300
committerCamila San <hello@camila.codes>2019-07-31 20:50:36 +0300
commit2ae6fe504a4caedd2bab0d05634153f2f2d0be67 (patch)
tree08e38fce1af180901b8c35c14fcf9e1ec1ffb07e
parent18d144b4e7e5e73959cbd56d7a447583d6284c51 (diff)
Fix: syncing all files on the first sync run.filestreaming-v9-2
Signed-off-by: Camila San <hello@camila.codes>
-rw-r--r--src/gui/syncwrapper.cpp9
-rw-r--r--src/gui/vfs_windows.cpp2
2 files changed, 6 insertions, 5 deletions
diff --git a/src/gui/syncwrapper.cpp b/src/gui/syncwrapper.cpp
index 9a5d0981e..71a2b4442 100644
--- a/src/gui/syncwrapper.cpp
+++ b/src/gui/syncwrapper.cpp
@@ -55,10 +55,12 @@ namespace OCC {
qDebug() << "sync mode: " << SyncJournalDb::instance()->getSyncMode(getRelativePath(path));
OCC::SyncJournalFileRecord rec;
- if (SyncJournalDb::instance()->getFileRecord(getRelativePath(path), &rec))
- if (rec._path.isEmpty()) {
+ if (SyncJournalDb::instance()->getFileRecord(getRelativePath(path), &rec)) {
+ qDebug() << "_etag: " << rec._etag;
+ if (rec._etag.isEmpty()) {
FolderMan::instance()->currentSyncFolder()->updateFuseCreatedFile(getRelativePath(path), true);
}
+ }
}
void SyncWrapper::createItemAtPath(const QString path)
@@ -103,14 +105,13 @@ namespace OCC {
qDebug() << Q_FUNC_INFO << "results: " << remoteNode->path << remoteNode->type;
OCC::SyncJournalFileRecord rec;
if (SyncJournalDb::instance()->getFileRecord(remoteNode->path, &rec)) {
- QByteArray fullPath(localPath.toLatin1() + remoteNode->path);
+ QByteArray fullPath(localPath.toLatin1());
if (csync_vio_local_stat(fullPath.constData(), remoteNode) == 0) {
rec._inode = remoteNode->inode;
qCDebug(lcSyncWrapper) << remoteNode->path << "Retrieved inode " << remoteNode->inode;
}
rec._path = remoteNode->path;
- //rec._etag = remoteNode->etag;
rec._fileId = remoteNode->file_id;
rec._modtime = remoteNode->modtime;
rec._type = remoteNode->type;
diff --git a/src/gui/vfs_windows.cpp b/src/gui/vfs_windows.cpp
index 5bbb20ebb..0ce3e5bd1 100644
--- a/src/gui/vfs_windows.cpp
+++ b/src/gui/vfs_windows.cpp
@@ -2669,7 +2669,7 @@ QStringList *VfsWindows::contentsOfDirectoryAtPath(QString path, QVariantMap &er
}
- SyncWrapper::instance()->setFileRecord(_fileListMap.value(path)->list.at(i).get(), rootPath + (path.endsWith("/")?path:(path+"/")));
+ SyncWrapper::instance()->setFileRecord(_fileListMap.value(path)->list.at(i).get(), completePath);
}
emit addToFileTree(_fileListMap.value(path)->list.at(i)->type, completePath);