diff options
-rw-r--r-- | gdb/ChangeLog | 4 | ||||
-rw-r--r-- | gdb/record.c | 11 |
2 files changed, 14 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 07c73d74142..f11e4771887 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2008-09-07 Hui Zhu <teawater@gmail.com> + + * record.c (record_wait): Add code to deal with record_first. + 2008-09-06 Michael Snyder <msnyder@vmware.com> * record-linux.c: Comment and message string cleanup. diff --git a/gdb/record.c b/gdb/record.c index 718ce4475b2..96a2aeed9c9 100644 --- a/gdb/record.c +++ b/gdb/record.c @@ -631,6 +631,13 @@ record_wait (ptid_t ptid, struct target_waitstatus *status) if (record_execdir == EXEC_FORWARD) { + if (record_list == &record_first) + { + /* The first record_t, not a really record_t. + Goto next record_t. */ + goto next; + } + need_dasm = record_list->u.need_dasm; } if (need_dasm) @@ -640,7 +647,8 @@ record_wait (ptid_t ptid, struct target_waitstatus *status) if (first_record_end && record_execdir == EXEC_REVERSE) { - /* When reverse excute, the first record_end is the part of current instruction */ + /* When reverse excute, the first record_end is the part of + current instruction. */ first_record_end = 0; } else @@ -697,6 +705,7 @@ record_wait (ptid_t ptid, struct target_waitstatus *status) } } +next: if (record_execdir == EXEC_REVERSE) { if (record_list->prev && continue_flag) |