diff options
author | Pedro Alves <palves@redhat.com> | 2015-04-07 11:42:09 +0100 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2015-04-07 11:42:09 +0100 |
commit | d9b67d9f4127191679c743d1f47d2421d6dcede7 (patch) | |
tree | 5d451af55a624cfccbd0741fdadaa583a7600ae7 /gdb/infrun.c | |
parent | 337532fab150dc531c92a31e179df96b98a619c0 (diff) | |
download | gdb-d9b67d9f4127191679c743d1f47d2421d6dcede7.zip gdb-d9b67d9f4127191679c743d1f47d2421d6dcede7.tar.gz gdb-d9b67d9f4127191679c743d1f47d2421d6dcede7.tar.bz2 |
Displaced stepping debug: fetch the right regcache
Although not currently possible in practice when we get here,
'resume_ptid' can also be a wildcard throughout this function. It's
clearer to fetch the regcache using the thread's ptid.
gdb/ChangeLog:
2015-04-07 Pedro Alves <pedro@codesourcery.com>
* infrun.c (resume) <displaced stepping debug output>: Get the
leader thread's regcache, not resume_ptid's.
Diffstat (limited to 'gdb/infrun.c')
-rw-r--r-- | gdb/infrun.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/infrun.c b/gdb/infrun.c index f5faa0a..607a6e4 100644 --- a/gdb/infrun.c +++ b/gdb/infrun.c @@ -2364,7 +2364,7 @@ resume (enum gdb_signal sig) && use_displaced_stepping (gdbarch) && tp->control.trap_expected) { - struct regcache *resume_regcache = get_thread_regcache (resume_ptid); + struct regcache *resume_regcache = get_thread_regcache (tp->ptid); struct gdbarch *resume_gdbarch = get_regcache_arch (resume_regcache); CORE_ADDR actual_pc = regcache_read_pc (resume_regcache); gdb_byte buf[4]; |