From 578e83501becca2aa0b2ff38380e8e2dc7508f7d Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 6 Aug 2008 17:48:44 -0400 Subject: [PATCH] BUG: Fix crash on circular target dependencies After reporting an error about circular target dependencies do not try to continue generation because the dependency computation object is not in a useful state. --- Source/cmGlobalGenerator.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index cf4abdd5e..a1f42cf53 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -860,7 +860,10 @@ void cmGlobalGenerator::Generate() // Compute the inter-target dependencies. { cmComputeTargetDepends ctd(this); - ctd.Compute(); + if(!ctd.Compute()) + { + return; + } std::vector const& targets = ctd.GetTargets(); for(std::vector::const_iterator ti = targets.begin(); ti != targets.end(); ++ti)