diff options
author | Tobias Hunger <tobias.hunger@qt.io> | 2019-07-25 15:16:55 +0200 |
---|---|---|
committer | Alexandru Croitor <alexandru.croitor@qt.io> | 2019-07-25 13:32:21 +0000 |
commit | eab0df22f98fab37585e4513de836a06e4aa05d5 (patch) | |
tree | e6c422f0c5237fd80c504f461c8c5ade43b3a0bb /src/plugins/cmakeprojectmanager/fileapireader.cpp | |
parent | ec9278477811a42dafe0694e94d49eb530a31587 (diff) |
CMake: Make fileapi not race against its own reply file detection
Fix broken logic to prevent CMake fileapi from detecting the change
its own cmake run triggered via file watching.
Remember the last file that was parsed and do not attempt to parse
this again. Remember the file on a per-project basis, too:-)
Change-Id: Ia6e155b65d77994f6e3d2a3677f770a4ba53539d
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'src/plugins/cmakeprojectmanager/fileapireader.cpp')
-rw-r--r-- | src/plugins/cmakeprojectmanager/fileapireader.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/cmakeprojectmanager/fileapireader.cpp b/src/plugins/cmakeprojectmanager/fileapireader.cpp index 82aa5542c5..377553563b 100644 --- a/src/plugins/cmakeprojectmanager/fileapireader.cpp +++ b/src/plugins/cmakeprojectmanager/fileapireader.cpp @@ -231,6 +231,8 @@ void FileApiReader::endState(const QFileInfo &replyFi) const FilePath sourceDirectory = m_parameters.sourceDirectory; const FilePath buildDirectory = m_parameters.workDirectory; + m_fileApi->setParsedReplyFilePath(replyFi.filePath()); + m_future = runAsync(ProjectExplorerPlugin::sharedThreadPool(), [replyFi, sourceDirectory, buildDirectory]() { auto result = std::make_unique<FileApiQtcData>(); |