diff options
author | Stephen Kelly <steveire@gmail.com> | 2011-12-04 15:45:39 (GMT) |
---|---|---|
committer | David Cole <david.cole@kitware.com> | 2012-02-22 11:31:49 (GMT) |
commit | 97a5faa85895ca77679d794788731cf76b8704ce (patch) | |
tree | 879adb8d0de0b4aa0d998492ea61650d31aa65b5 /Source/cmLocalGenerator.cxx | |
parent | edd5303949f9d0e1b4b11e83aecd34bfdb2700ce (diff) | |
download | CMake-97a5faa85895ca77679d794788731cf76b8704ce.zip CMake-97a5faa85895ca77679d794788731cf76b8704ce.tar.gz CMake-97a5faa85895ca77679d794788731cf76b8704ce.tar.bz2 |
Make it safe to call this method without creating duplicates.
Diffstat (limited to 'Source/cmLocalGenerator.cxx')
-rw-r--r-- | Source/cmLocalGenerator.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index b02fc36..961de37 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -1378,8 +1378,12 @@ void cmLocalGenerator::GetIncludeDirectories(std::vector<std::string>& dirs, // Store the automatic include paths. if(includeBinaryDir) { - dirs.push_back(this->Makefile->GetStartOutputDirectory()); - emitted.insert(this->Makefile->GetStartOutputDirectory()); + if(emitted.find( + this->Makefile->GetStartOutputDirectory()) == emitted.end()) + { + dirs.push_back(this->Makefile->GetStartOutputDirectory()); + emitted.insert(this->Makefile->GetStartOutputDirectory()); + } } if(includeSourceDir) { |