1
0
Fork 0
mirror of https://github.com/tobast/libunwind-eh_elf.git synced 2024-11-17 13:47:37 +01:00
libunwind-eh_elf/src/dwarf
Konstantin Baladurin 36b46f1921 dwarf/Gparser: fix crash during unwinding (#46)
We should update locations of the registers after all of them will
be restored. Otherwise some locations will be incorrect.

For example if function stores ebp, edi, esi and ebx registers on
stack in its prologue, compiler can generate following unwind info:
DW_CFA_expression: r5 (ebp) (DW_OP_breg5 (ebp): 0)
DW_CFA_expression: r7 (edi) (DW_OP_breg5 (ebp): -4)
DW_CFA_expression: r6 (esi) (DW_OP_breg5 (ebp): -8)
DW_CFA_expression: r3 (ebx) (DW_OP_breg5 (ebp): -12)

In this case locations of the ebx and ebp will be calculated using
current ebp but locations of the esi and edi will be calculated using
previous (restored) one. Due to it their locations will be incorrect
and it could lead to crash if we will try to get esi or edi value.

This patch fixes this problem.
2017-10-17 11:27:43 -07:00
..
Gexpr.c mips: fix compiler warnings 2017-02-14 08:18:49 -08:00
Gfde.c aarch64: PLT entry recognition & fixes 2017-08-18 09:55:49 -07:00
Gfind_proc_info-lsb.c aarch64: PLT entry recognition & fixes 2017-08-18 09:55:49 -07:00
Gfind_unwind_table.c dwarf: fix synthetic eh_frame_hdr 2017-07-06 09:15:08 -07:00
global.c Remove next field from dwarf_reg_state. Create new struct 2017-05-12 22:24:00 -05:00
Gparser.c dwarf/Gparser: fix crash during unwinding (#46) 2017-10-17 11:27:43 -07:00
Gpe.c One time whitespace fixup. 2014-09-27 09:47:23 -07:00
Lexpr.c Regenerate. 2004-08-17 15:34:28 +00:00
Lfde.c Regenerate. 2004-08-17 15:34:28 +00:00
Lfind_proc_info-lsb.c (Logical change 1.145) 2003-12-20 11:43:08 +00:00
Lfind_unwind_table.c Move some dwarf functionality from ptrace to dwarf 2012-03-12 20:06:37 -07:00
Lparser.c Regenerate. 2004-08-17 15:34:28 +00:00
Lpe.c Regenerate. 2004-08-17 15:34:28 +00:00