From a010605fef0eba73c564c3dd22e0a6ecbc26b10e Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Thu, 16 Apr 2020 07:24:57 -0600 Subject: Fix Cygwin gdb build Simon pointed out that the windows-nat sharing series broke the Cygwin build. This patch fixes the problem, by moving the Cygwin-specific code to a new handler function. This approach is taken because this code calls find_pc_partial_function, which isn't available in gdbserver. gdb/ChangeLog 2020-04-16 Tom Tromey * windows-nat.c (windows_nat::handle_access_violation): New function. * nat/windows-nat.h (handle_access_violation): Declare. * nat/windows-nat.c (handle_exception): Move Cygwin code to windows-nat.c. Call handle_access_violation. gdbserver/ChangeLog 2020-04-16 Tom Tromey * win32-low.cc (windows_nat::handle_access_violation): New function. --- gdbserver/ChangeLog | 5 +++++ gdbserver/win32-low.cc | 8 ++++++++ 2 files changed, 13 insertions(+) (limited to 'gdbserver') diff --git a/gdbserver/ChangeLog b/gdbserver/ChangeLog index 2abe0f1..96642e5 100644 --- a/gdbserver/ChangeLog +++ b/gdbserver/ChangeLog @@ -1,3 +1,8 @@ +2020-04-16 Tom Tromey + + * win32-low.cc (windows_nat::handle_access_violation): New + function. + 2020-04-15 Simon Marchi * win32-low.cc (get_child_debug_event): Fix format string warning. diff --git a/gdbserver/win32-low.cc b/gdbserver/win32-low.cc index 75305a4..5a6f0df 100644 --- a/gdbserver/win32-low.cc +++ b/gdbserver/win32-low.cc @@ -1198,6 +1198,14 @@ windows_nat::handle_ms_vc_exception (const EXCEPTION_RECORD *rec) return false; } +/* See nat/windows-nat.h. */ + +bool +windows_nat::handle_access_violation (const EXCEPTION_RECORD *rec) +{ + return false; +} + /* A helper function that will, if needed, set 'stopped_at_software_breakpoint' on the thread and adjust the PC. */ -- cgit v1.1