From fd410a5a847f75a1eeefa385b49367be48af8d32 Mon Sep 17 00:00:00 2001 From: Olivier Goffart Date: Tue, 18 Dec 2018 10:38:39 +0100 Subject: [PATCH] SyncEngine: Ensure that the paths passed to the discovery ends with slashes This was making the tx.pl test fail --- src/libsync/syncengine.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/libsync/syncengine.cpp b/src/libsync/syncengine.cpp index 1a96ed657..418d494fc 100644 --- a/src/libsync/syncengine.cpp +++ b/src/libsync/syncengine.cpp @@ -579,7 +579,11 @@ void SyncEngine::slotStartDiscovery() _discoveryPhase->_excludes = _excludedFiles.data(); _discoveryPhase->_statedb = _journal; _discoveryPhase->_localDir = _localPath; + if (!_discoveryPhase->_localDir.endsWith('/')) + _discoveryPhase->_localDir+='/'; _discoveryPhase->_remoteFolder = _remotePath; + if (!_discoveryPhase->_remoteFolder.endsWith('/')) + _discoveryPhase->_remoteFolder+='/'; _discoveryPhase->_syncOptions = _syncOptions; _discoveryPhase->_shouldDiscoverLocaly = [this](const QString &s) { return shouldDiscoverLocally(s); }; _discoveryPhase->_selectiveSyncBlackList = selectiveSyncBlackList; -- 2.30.2