aboutsummaryrefslogtreecommitdiff
path: root/gdb/breakpoint.c
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2011-07-26 19:39:59 +0000
committerPedro Alves <palves@redhat.com>2011-07-26 19:39:59 +0000
commitefa80663c6860c65971ea1d3e6284c2676074d10 (patch)
tree7140b58d4636a9ec58c40ae048f27e8b62d0148b /gdb/breakpoint.c
parentffdd6afc609db5cc7f86bdb2169ff7ad2eb3875f (diff)
downloadgdb-efa80663c6860c65971ea1d3e6284c2676074d10.zip
gdb-efa80663c6860c65971ea1d3e6284c2676074d10.tar.gz
gdb-efa80663c6860c65971ea1d3e6284c2676074d10.tar.bz2
2011-07-26 Pedro Alves <pedro@codesourcery.com>
gdb/ * breakpoint.c (works_in_software_mode_watchpoint): Also return true for software watchpoints. gdb/testsuite/ * gdb.base/watchpoint.exp (test_disable_enable_software_watchpoint): New procedure. (top level): Run it.
Diffstat (limited to 'gdb/breakpoint.c')
-rw-r--r--gdb/breakpoint.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
index 5afda31..00fe748 100644
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -8637,7 +8637,8 @@ resources_needed_watchpoint (const struct bp_location *bl)
static int
works_in_software_mode_watchpoint (const struct breakpoint *b)
{
- return b->type == bp_hardware_watchpoint;
+ /* Read and access watchpoints only work with hardware support. */
+ return b->type == bp_watchpoint || b->type == bp_hardware_watchpoint;
}
static enum print_stop_action