aboutsummaryrefslogtreecommitdiff
path: root/gdb/i386-darwin-nat.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@polymtl.ca>2017-03-17 13:55:56 -0400
committerSimon Marchi <simon.marchi@ericsson.com>2017-03-17 13:55:56 -0400
commit1afaf9f42fe201872d758214beceff85325a988a (patch)
tree5ef4130cf120ef753a2c20753ff556bbc3475054 /gdb/i386-darwin-nat.c
parentaac12e2497a42b47223680ab1b5924137de77c9a (diff)
downloadgdb-1afaf9f42fe201872d758214beceff85325a988a.zip
gdb-1afaf9f42fe201872d758214beceff85325a988a.tar.gz
gdb-1afaf9f42fe201872d758214beceff85325a988a.tar.bz2
i386-darwin-nat: Use ptid from regcache instead of inferior_ptid
gdb/ChangeLog: * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers, i386_darwin_store_inferior_registers): Use ptid from regcache.
Diffstat (limited to 'gdb/i386-darwin-nat.c')
-rw-r--r--gdb/i386-darwin-nat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/i386-darwin-nat.c b/gdb/i386-darwin-nat.c
index 4bffe6d..dc7ce32 100644
--- a/gdb/i386-darwin-nat.c
+++ b/gdb/i386-darwin-nat.c
@@ -50,7 +50,7 @@ static void
i386_darwin_fetch_inferior_registers (struct target_ops *ops,
struct regcache *regcache, int regno)
{
- thread_t current_thread = ptid_get_tid (inferior_ptid);
+ thread_t current_thread = ptid_get_tid (regcache_get_ptid (regcache));
int fetched = 0;
struct gdbarch *gdbarch = get_regcache_arch (regcache);
@@ -167,7 +167,7 @@ static void
i386_darwin_store_inferior_registers (struct target_ops *ops,
struct regcache *regcache, int regno)
{
- thread_t current_thread = ptid_get_tid (inferior_ptid);
+ thread_t current_thread = ptid_get_tid (regcache_get_ptid (regcache));
struct gdbarch *gdbarch = get_regcache_arch (regcache);
#ifdef BFD64