SyncEngine: Handle upgrade case from 1.8.0

If 1.8.0 caused missing data in the local tree, this patch gets it
back. For that, the usage of the journal for remote repository is
disabled at the first start.
Esse commit está contido em:
Klaas Freitag
2015-05-04 12:14:35 +02:00
commit d63abef718
3 arquivos alterados com 26 adições e 1 exclusões
+8 -1
Ver Arquivo
@@ -605,7 +605,14 @@ void SyncEngine::startSync()
// database creation error!
}
if (fileRecordCount >= 1 && isUpdateFrom_1_5) {
bool isUpdateFrom_1_8 = _journal->isUpdateFrom_1_8_0();
/*
* If 1.8.0 caused missing data in the local tree, this patch gets it
* back. For that, the usage of the journal for remote repository is
* disabled at the first start.
*/
if (fileRecordCount >= 1 && (isUpdateFrom_1_5 || isUpdateFrom_1_8)) {
qDebug() << "detected update from 1.5" << fileRecordCount << isUpdateFrom_1_5;
// Disable the read from DB to be sure to re-read all the fileid and etags.
_csync_ctx->read_remote_from_db = false;