This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] Make access watchpoints work again
Earlier in the thread "Unified watchpoints for x86 platforms" I
mentioned that awatch causes GDB to call internal_error. The patch
below fixes the problem which was causing this. It looks like two
lines mysteriously changed places (and were later reindented).
I wish all bugs were as easy to find and fix as this one ;-)
Okay to commit?
(Btw, why isn't the case, where an access watchpoint triggers, but the
value didn't change, being annotated with a call to
annotate_watchpoint?)
2001-03-18 Eli Zaretskii <eliz@is.elta.co.il>
* breakpoint.c (print_it_typical) <bp_access_watchpoint> [UI_OUT]:
Correct the order of calls to ui_out_field_string and
ui_out_list_begin when bs->old_val is NULL.
--- gdb/breakpoint.c~0 Wed Jan 31 03:24:00 2001
+++ gdb/breakpoint.c Sun Mar 18 20:34:06 2001
@@ -2093,8 +2093,8 @@ print_it_typical (bpstat bs)
{
mention (bs->breakpoint_at);
if (interpreter_p && strcmp (interpreter_p, "mi") == 0)
- ui_out_list_begin (uiout, "value");
- ui_out_field_string (uiout, "reason", "access-watchpoint-trigger");
+ ui_out_field_string (uiout, "reason", "access-watchpoint-trigger");
+ ui_out_list_begin (uiout, "value");
ui_out_text (uiout, "\nValue = ");
}
value_print (bs->breakpoint_at->val, stb->stream, 0,Val_pretty_default);