Avoid warnings when asserts are disabled.

llvm-svn: 309326
This commit is contained in:
Rafael Espindola 2017-07-27 21:42:42 +00:00
parent c890993726
commit a2df2f09f4
1 changed files with 1 additions and 2 deletions

View File

@ -428,8 +428,7 @@ void LinkerScript::addOrphanSections(OutputSectionFactory &Factory) {
});
if (I == End) {
Factory.addInputSec(S, Name);
OutputSection *Sec = S->getOutputSection();
assert(Sec->SectionIndex == INT_MAX);
assert(S->getOutputSection()->SectionIndex == INT_MAX);
} else {
OutputSection *Sec = cast<OutputSection>(*I);
Factory.addInputSec(S, Name, Sec);