[llvm-readobj] Fix output of MIPS GOT without local and global entries.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212374 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Simon Atanasyan
2014-07-05 19:28:49 +00:00
parent db8cb2223d
commit ad720cfde4
3 changed files with 26 additions and 1 deletions

View File

@@ -1087,7 +1087,7 @@ void MipsGOTParser<ELFT>::parseGOT(const Elf_Shdr &GOTShdr) {
Elf_Sym_Iter DynSymEnd = Obj->end_dynamic_symbols();
std::size_t DynSymTotal = std::size_t(std::distance(DynSymBegin, DynSymEnd));
if (DtGotSym + 1 > DynSymTotal) {
if (DtGotSym > DynSymTotal) {
W.startLine() << "MIPS_GOTSYM exceeds a number of dynamic symbols.\n";
return;
}