mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-08 07:10:12 -05:00
Add a null check to the generator target accessor.
This commit is contained in:
@@ -4061,8 +4061,11 @@ bool cmMakefile::IsAlias(const char *name)
|
||||
//----------------------------------------------------------------------------
|
||||
cmGeneratorTarget* cmMakefile::FindGeneratorTargetToUse(const char* name)
|
||||
{
|
||||
cmTarget *t = this->FindTargetToUse(name);
|
||||
return this->LocalGenerator->GetGlobalGenerator()->GetGeneratorTarget(t);
|
||||
if (cmTarget *t = this->FindTargetToUse(name))
|
||||
{
|
||||
return this->LocalGenerator->GetGlobalGenerator()->GetGeneratorTarget(t);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user