data: Fix file node search with concatenated file path in storage fails for relative paths containing ..

This commit is contained in:
Eberhard Graether
2017-01-27 10:30:26 +01:00
parent a9153a8416
commit 590f4138e1
+1 -2
View File
@@ -962,13 +962,12 @@ std::vector<Id> PersistentStorage::getLocalSymbolIdsForLocationIds(const std::ve
std::vector<Id> PersistentStorage::getTokenIdsForMatches(const std::vector<SearchMatch>& matches) const
{
FilePath rootPath = getDbFilePath().parentDirectory();
std::set<Id> idSet;
for (const SearchMatch& match : matches)
{
if (match.nodeType == Node::NODE_FILE)
{
idSet.insert(m_sqliteStorage.getFileByPath(rootPath.concat(match.subtext).str()).id);
idSet.insert(m_sqliteStorage.getFileByPath(match.name).id);
}
else
{