aboutsummaryrefslogtreecommitdiff
path: root/ylwrap
diff options
context:
space:
mode:
authorHannes Domani <ssbssa@yahoo.de>2020-01-17 15:28:09 +0100
committerHannes Domani <ssbssa@yahoo.de>2020-02-09 12:14:51 +0100
commit7928d571c5f742a10d98b0de0ef85284c5959845 (patch)
tree3a728942f516e96dc543fc73b17b848f7aa9849d /ylwrap
parent98d3eb9390ef5eca14200c424f22812982c06b19 (diff)
downloadgdb-7928d571c5f742a10d98b0de0ef85284c5959845.zip
gdb-7928d571c5f742a10d98b0de0ef85284c5959845.tar.gz
gdb-7928d571c5f742a10d98b0de0ef85284c5959845.tar.bz2
Display ExceptionRecord for $_siginfo
Uses the $_siginfo convenience variable to show the last exception. The type looks like this: (gdb) pt $_siginfo type = struct EXCEPTION_RECORD { DWORD ExceptionCode; DWORD ExceptionFlags; struct EXCEPTION_RECORD *ExceptionRecord; PVOID ExceptionAddress; DWORD NumberParameters; ULONG_PTR ExceptionInformation[15]; } EXCEPTION_RECORD is documented at [1]. Example: Program received signal SIGSEGV, Segmentation fault. main () at crasher.c:4 4 *(int*)0x123 = 0; (gdb) p $_siginfo $1 = { ExceptionCode = 3221225477, ExceptionFlags = 0, ExceptionRecord = 0x0, ExceptionAddress = 0x401632 <main+18>, NumberParameters = 2, ExceptionInformation = {1, 291, 0 <repeats 13 times>} } (gdb) p/x $_siginfo.ExceptionCode $2 = 0xc0000005 (gdb) p/x $_siginfo.ExceptionInformation[1] $3 = 0x123 And 0xc0000005 is the value of EXCEPTION_ACCESS_VIOLATION. [1] https://docs.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-exception_record gdb/ChangeLog: 2020-02-09 Hannes Domani <ssbssa@yahoo.de> * NEWS: Mention $_siginfo support for Windows. * windows-nat.c (handle_exception): Set siginfo_er. (windows_nat_target::mourn_inferior): Reset siginfo_er. (windows_xfer_siginfo): New function. (windows_nat_target::xfer_partial): Call windows_xfer_siginfo. * windows-tdep.c (struct windows_gdbarch_data): New struct. (init_windows_gdbarch_data): New function. (get_windows_gdbarch_data): New function. (windows_get_siginfo_type): New function. (windows_init_abi): Register windows_get_siginfo_type. (_initialize_windows_tdep): Register init_windows_gdbarch_data. gdbserver/ChangeLog: 2020-02-09 Hannes Domani <ssbssa@yahoo.de> * win32-low.c (win32_clear_inferiors): Reset siginfo_er. (handle_exception): Set siginfo_er. (win32_xfer_siginfo): New function.
Diffstat (limited to 'ylwrap')
0 files changed, 0 insertions, 0 deletions