summaryrefslogtreecommitdiff
path: root/src/plugins/cpptools/cppmodelmanager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/cpptools/cppmodelmanager.cpp')
-rw-r--r--src/plugins/cpptools/cppmodelmanager.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/cpptools/cppmodelmanager.cpp b/src/plugins/cpptools/cppmodelmanager.cpp
index 6a49051840..b0f3838a4e 100644
--- a/src/plugins/cpptools/cppmodelmanager.cpp
+++ b/src/plugins/cpptools/cppmodelmanager.cpp
@@ -379,8 +379,8 @@ QString CppPreprocessor::tryIncludeFile(QString &fileName, IncludeType type)
}
}
- foreach (const QString &includePath, m_includePaths) {
- QString path = includePath;
+ for (int i = m_includePaths.size() - 1; i != -1; --i) {
+ QString path = m_includePaths.at(i);
path += QLatin1Char('/');
path += fileName;
path = QDir::cleanPath(path);