OSDN Git Service

* breakpoint.c (fetch_watchpoint_value): New function.
authordrow <drow>
Mon, 3 Mar 2008 13:24:11 +0000 (13:24 +0000)
committerdrow <drow>
Mon, 3 Mar 2008 13:24:11 +0000 (13:24 +0000)
commit5944fe21f60a1cdd8589fcce86f02488d9fd0122
tree44f557f82bb6ff4f4efd37fe40b77b9dc7d1a2b5
parentd281236259dcdff1ecc6df32dca6d051186a52a1
* breakpoint.c (fetch_watchpoint_value): New function.
(update_watchpoint): Set and clear val_valid.  Use
fetch_watchpoint_value.  Handle unreadable values on the
value chain.  Correct check for user-requested array watchpoints.
(breakpoint_init_inferior): Clear val_valid.
(watchpoint_value_print): New function.
(print_it_typical): Use it.  Do not free or clear old_val.  Print
watchpoints even if old_val == NULL.
(watchpoint_check): Use fetch_watchpoint_value.  Check for values
becoming readable or unreadable.
(watch_command_1): Use fetch_watchpoint_value.  Set val_valid.
(do_enable_watchpoint): Likewise.
* breakpoint.h (struct breakpoint): Update comment for val.  Add
val_valid.
* NEWS: Mention watchpoints on inaccessible memory.

* gdb.base/watchpoint.c (global_ptr, func4): New.
(main): Call func4.
* gdb.base/watchpoint.exp: Call test_inaccessible_watchpoint.
(test_inaccessible_watchpoint): New.

* gdb.texinfo (Set Watchpoints): Mention watchpoints on
unreadable memory.  Delete obsolete SPARClite reference.
gdb/ChangeLog
gdb/NEWS
gdb/breakpoint.c
gdb/breakpoint.h
gdb/doc/ChangeLog
gdb/doc/gdb.texinfo
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/watchpoint.c
gdb/testsuite/gdb.base/watchpoint.exp