[all-commits] [llvm/llvm-project] d6d6fd: [llvm-readobj/elf] - Fix a crash when dumping a dy...

Georgii Rymar via All-commits all-commits at lists.llvm.org
Thu Oct 29 05:39:35 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: d6d6fdb068afd043b9cfb9c7b5adbc29b1440aad
      https://github.com/llvm/llvm-project/commit/d6d6fdb068afd043b9cfb9c7b5adbc29b1440aad
  Author: Georgii Rymar <grimar at accesssoftek.com>
  Date:   2020-10-29 (Thu, 29 Oct 2020)

  Changed paths:
    M llvm/test/tools/llvm-readobj/ELF/broken-dynamic-reloc.test
    M llvm/tools/llvm-readobj/ELFDumper.cpp

  Log Message:
  -----------
  [llvm-readobj/elf] - Fix a crash when dumping a dynamic relocation that refer to a symbol past the EOF.

There is a possible scenario when we crash when dumping dynamic relocations.
For that we should have no section headers (to take the number of synamic symbols from)
and a dynamic relocation that refers to a symbol with an index that is too large to be in a file.

The patch fixes it.

Differential revision: https://reviews.llvm.org/D90214




More information about the All-commits mailing list