BUG: Fix PARENT_DIRECTORY property in top-level to not crash.
This commit is contained in:
parent
bb7bc28c78
commit
2ca9a70fd1
|
@ -2908,8 +2908,10 @@ const char *cmMakefile::GetProperty(const char* prop,
|
||||||
output = "";
|
output = "";
|
||||||
if (!strcmp("PARENT_DIRECTORY",prop))
|
if (!strcmp("PARENT_DIRECTORY",prop))
|
||||||
{
|
{
|
||||||
output = this->LocalGenerator->GetParent()
|
if(cmLocalGenerator* plg = this->LocalGenerator->GetParent())
|
||||||
->GetMakefile()->GetStartDirectory();
|
{
|
||||||
|
output = plg->GetMakefile()->GetStartDirectory();
|
||||||
|
}
|
||||||
return output.c_str();
|
return output.c_str();
|
||||||
}
|
}
|
||||||
else if (!strcmp("INCLUDE_REGULAR_EXPRESSION",prop) )
|
else if (!strcmp("INCLUDE_REGULAR_EXPRESSION",prop) )
|
||||||
|
|
Loading…
Reference in New Issue