From c7437ca6e4ecefbaa0a0ebef0e68f09f8f19c449 Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Thu, 4 Mar 2010 15:37:26 +0000 Subject: gdb/ * breakpoint.c (update_watchpoint): Create a sentinel location if the software watchpoint isn't watching any memory. (breakpoint_address_bits): Skip dummy software watchpoint locations. gdb/testsuite/ * gdb.base/watch-non-mem.c, gdb.base/watch-non-mem.exp: New. --- gdb/testsuite/gdb.base/watch-non-mem.c | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 gdb/testsuite/gdb.base/watch-non-mem.c (limited to 'gdb/testsuite/gdb.base/watch-non-mem.c') diff --git a/gdb/testsuite/gdb.base/watch-non-mem.c b/gdb/testsuite/gdb.base/watch-non-mem.c new file mode 100644 index 0000000..8474657 --- /dev/null +++ b/gdb/testsuite/gdb.base/watch-non-mem.c @@ -0,0 +1,27 @@ +/* This testcase is part of GDB, the GNU debugger. + + Copyright 2010 Free Software Foundation, Inc. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +int global = 0; + +int main() +{ + global++; + global++; + global++; + + return 0; +} -- cgit v1.1