-fix documentation from a module which has *only* documentation
This is #10466. It didn't crash for me, but also didn't work. The issue was that a line ending with something else than a # was considered as the end of the documentation block. If there was simply the end of the file we didn't get into the correct branch. Alex
This commit is contained in:
parent
d1b3ceb88c
commit
d62c51ddc2
|
@ -606,10 +606,15 @@ bool cmDocumentation::CreateSingleModule(const char* fname,
|
|||
}
|
||||
else
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(text.length() < 2 && brief.length() == 1)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
char* pname = strcpy(new char[strlen(moduleName)+1], moduleName);
|
||||
char* ptext = strcpy(new char[text.length()+1], text.c_str());
|
||||
this->ModuleStrings.push_back(pname);
|
||||
|
@ -618,9 +623,6 @@ bool cmDocumentation::CreateSingleModule(const char* fname,
|
|||
this->ModuleStrings.push_back(pbrief);
|
||||
moduleSection.Append(pname, pbrief, ptext);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue