New disco algo: Fix TestSyncFileStatusTracker
authorOlivier Goffart <ogoffart@woboq.com>
Wed, 18 Jul 2018 10:15:13 +0000 (12:15 +0200)
committerKevin Ottens <kevin.ottens@nextcloud.com>
Tue, 15 Dec 2020 09:57:59 +0000 (10:57 +0100)
src/libsync/syncengine.cpp

index b45a3259a8f8ebac2bbbf6d53fc50f764ac0a608..aa1ea5bd5f3c82d4b472d854335d3ac90a9c0518 100644 (file)
@@ -440,6 +440,11 @@ void OCC::SyncEngine::slotItemDiscovered(const OCC::SyncFileItemPtr &item)
             }
         }
     }
+
+    // check for blacklisting of this item.
+    // if the item is on blacklist, the instruction was set to ERROR
+    checkErrorBlacklisting(*item);
+    _needsUpdate = true;
     _syncItems.append(item);
     slotNewItem(item);
 }
@@ -607,15 +612,6 @@ int SyncEngine::treewalkFile(csync_file_stat_t * /*file*/, csync_file_stat_t * /
         break;
     }
 
-    item->_direction = dir;
-    if (instruction != CSYNC_INSTRUCTION_NONE) {
-        // check for blacklisting of this item.
-        // if the item is on blacklist, the instruction was set to ERROR
-        checkErrorBlacklisting(*item);
-    }
-
-    _needsUpdate = true;
-
 
 
     slotNewItem(item);