1
diff -urN gdb-orig/gdb/breakpoint.c gdb-6.6/gdb/breakpoint.c
2
--- gdb-orig/gdb/breakpoint.c 2007-02-28 21:32:57.000000000 +0100
3
+++ gdb-6.6/gdb/breakpoint.c 2007-03-03 00:10:36.998120112 +0100
5
don't know what the overlay manager might do. */
6
if (b->loc_type == bp_loc_hardware_breakpoint)
7
val = target_remove_hw_breakpoint (&b->target_info);
10
+ /* However, we should remove *software* breakpoints only
11
+ if the section is still mapped, or else we overwrite
12
+ wrong code with the saved shadow contents. */
13
+ else if (section_is_mapped (b->section))
14
val = target_remove_breakpoint (&b->target_info);