Merge topic 'FixCrashInGraphVizWriter'

00e7ea7 Fix crash in GraphVizWriter when GRAPHVIZ_TARGET_IGNORE_REGEX is used
This commit is contained in:
Brad King 2011-02-08 14:18:48 -05:00 committed by CMake Topic Stage
commit 7f87205161
1 changed files with 6 additions and 0 deletions

View File

@ -272,6 +272,12 @@ void cmGraphVizWriter::WriteConnections(const char* targetName,
std::map<cmStdString, cmStdString>::const_iterator libNameIt =
this->TargetNamesNodes.find(libName);
// can happen e.g. if GRAPHVIZ_TARGET_IGNORE_REGEX is used
if(libNameIt == this->TargetNamesNodes.end())
{
continue;
}
std::string connectionName = myNodeName;
connectionName += "-";
connectionName += libNameIt->second;