diff --git a/include/llvm/Object/ELF.h b/include/llvm/Object/ELF.h index 9e8b6fafd89..43a5a86f201 100644 --- a/include/llvm/Object/ELF.h +++ b/include/llvm/Object/ELF.h @@ -1486,8 +1486,7 @@ ELFObjectFile::getRelocatedSection(DataRefImpl Sec) const { if (sh_type != ELF::SHT_RELA && sh_type != ELF::SHT_REL) return end_sections(); - unsigned SecIndex = S->sh_info; - assert(SecIndex != 0); + assert(S->sh_info != 0); const Elf_Shdr *R = getSection(S->sh_info); DataRefImpl D; D.p = reinterpret_cast(R);