Fix mismatched sign comparison

llvm-svn: 244653
This commit is contained in:
Reid Kleckner 2015-08-11 20:06:51 +00:00
parent 82d91ddb4f
commit f7b85e0ce2
1 changed files with 1 additions and 1 deletions

View File

@ -59,7 +59,7 @@ template <class ELFT> void elf2::ObjectFile<ELFT>::initializeSymbols() {
StringRef StringTable = *StringTableOrErr;
Elf_Sym_Range Syms = ELFObj->symbols(Symtab);
auto NumSymbols = std::distance(Syms.begin(), Syms.end());
uint32_t NumSymbols = std::distance(Syms.begin(), Syms.end());
uint32_t FirstNonLocal = Symtab->sh_info;
if (FirstNonLocal > NumSymbols)
error("Invalid sh_info in symbol table");