[PATCH] D79853: [llvm-readobj] - --gnu-hash-table: do not crash when the GNU hash table goes past the EOF.

George Rimar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri May 15 01:35:45 PDT 2020


grimar marked 2 inline comments as done.
grimar added inline comments.


================
Comment at: llvm/tools/llvm-readobj/ELFDumper.cpp:2681
+  const char *TableData = reinterpret_cast<const char *>(GnuHashTable);
+  assert(TableData >= File.getBufferStart() &&
+         TableData < File.getBufferEnd() &&
----------------
MaskRay wrote:
> IIRC this is guaranteed by `ELFFile<ELFT>::toMappedAddr`
Yes.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D79853/new/

https://reviews.llvm.org/D79853





More information about the llvm-commits mailing list