From: Markus Metzger Date: Fri, 4 Sep 2015 08:33:05 +0000 (+0200) Subject: btrace: add missing NO_HISTORY X-Git-Tag: users/hjl/linux/release/2.25.51.0.4~1^2~26^2~47 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cf8f8f0c4244b4980ce538680f81de3738ba08d6;p=thirdparty%2Fbinutils-gdb.git btrace: add missing NO_HISTORY If a single-step ended right at the end of the execution history, we forgot to announce that. Fix it. gdb/ * record-btrace.c (record_btrace_single_step_forward): Return NO_HISTORY if a step brings us to the end of the execution history. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index e50557f41a4..3fafdeff629 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2015-09-18 Markus Metzger + + * record-btrace.c (record_btrace_single_step_forward): Return + NO_HISTORY if a step brings us to the end of the execution history. + 2015-09-18 Markus Metzger * record-btrace.c (record_btrace_step_thread): Move breakpoint check diff --git a/gdb/record-btrace.c b/gdb/record-btrace.c index 5e8c1d40285..fcd4351f6b6 100644 --- a/gdb/record-btrace.c +++ b/gdb/record-btrace.c @@ -2061,7 +2061,10 @@ record_btrace_single_step_forward (struct thread_info *tp) /* We stop replaying if we reached the end of the trace. */ if (btrace_insn_cmp (replay, &end) == 0) - record_btrace_stop_replaying (tp); + { + record_btrace_stop_replaying (tp); + return btrace_step_no_history (); + } return btrace_step_spurious (); }