diff --git a/Source/cmGlobalVisualStudio8Generator.cxx b/Source/cmGlobalVisualStudio8Generator.cxx index be0f1a2fd..e4948a327 100644 --- a/Source/cmGlobalVisualStudio8Generator.cxx +++ b/Source/cmGlobalVisualStudio8Generator.cxx @@ -156,7 +156,7 @@ void cmGlobalVisualStudio8Generator::WriteSLNFile( std::vector dspnames = static_cast(generators[i]) ->GetCreatedProjectNames(); - cmTargets &tgts = generators[i]->GetMakefile()->GetTargets(); + cmTargets& tgts = mf->GetTargets(); for(cmTargets::iterator l = tgts.begin(); l != tgts.end(); ++l) { if(l->first == CMAKE_CHECK_BUILD_SYSTEM_TARGET)