From 879d1e6b4674bc8c09b64dafad9248fb782c8924 Mon Sep 17 00:00:00 2001 From: Ulrich Weigand Date: Tue, 26 Aug 2008 17:36:44 +0000 Subject: * breakpoint.c (remove_breakpoint): Do not fail if unable to remove breakpoint from shared library. --- gdb/ChangeLog | 5 +++++ gdb/breakpoint.c | 7 +++++++ 2 files changed, 12 insertions(+) (limited to 'gdb') diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 845b3b5..0477f24 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,10 @@ 2008-08-26 Ulrich Weigand + * breakpoint.c (remove_breakpoint): Do not fail if unable to remove + breakpoint from shared library. + +2008-08-26 Ulrich Weigand + * solib-svr4.c (read_program_header): New function. (scan_dyntag_auxv): New function. (elf_locate_base): Use it if scan_dyntag fails. diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c index 18e207f..847de00 100644 --- a/gdb/breakpoint.c +++ b/gdb/breakpoint.c @@ -1665,6 +1665,13 @@ remove_breakpoint (struct bp_location *b, insertion_state_t is) val = 0; } } + + /* In some cases, we might not be able to remove a breakpoint + in a shared library that has already been removed, but we + have not yet processed the shlib unload event. */ + if (val && solib_address (b->address)) + val = 0; + if (val) return val; b->inserted = (is == mark_inserted); -- cgit v1.1