llvm-project/libunwind
Jorge Gorbe Moya 82576d6fec [libunwind] Fix UB in EHHeaderParser::findFDE
When the EHHeaderInfo object filled by decodeEHHdr has fde_count == 0,
findFDE does the following:

- sets low = 0 and len = hdrInfo.fde_count as a preparation to start a
  binary search
- because len is 0, the binary search loop is skipped
- the code still tries to find a table entry at
  hdrInfo.table + low * tableEntrySize, and decode it.

This is wrong when fde_count is 0, and trying to decode a table entry
that isn't there will lead to reading garbage offsets and can cause
segfaults.

Differential Revision: https://reviews.llvm.org/D77679
2020-04-07 14:44:42 -07:00
..
cmake [unwind] Don't link libpthread and libdl on Fuchsia 2019-12-17 17:21:43 -08:00
docs Doc: Links should use https 2020-03-22 22:49:33 +01:00
include unwind: rename `__personality_routine` to `_Unwind_Personality_Fn` 2020-02-10 08:52:31 -08:00
src [libunwind] Fix UB in EHHeaderParser::findFDE 2020-04-07 14:44:42 -07:00
test [libunwind] Support the new libc++ test format 2020-04-06 23:26:59 +03:00
.clang-format
CMakeLists.txt [libunwind] Fix building standalone after c48974ffd7 2020-01-26 22:12:40 +02:00
LICENSE.TXT Fix typos throughout the license files that somehow I and my reviewers 2019-01-21 09:52:34 +00:00