summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2020-04-13 19:26:22 +0100
committerPedro Alves <palves@redhat.com>2020-06-03 20:36:14 +0100
commitec8096a4679658cea2c9983fb8970ede3b759070 (patch)
tree53e738706c6457fc9887b5a83155c1ed44111ff3
parent5d0840fc14578194c09a27e0193fc099d58fc216 (diff)
downloadbinutils-gdb-ec8096a4679658cea2c9983fb8970ede3b759070.tar.gz
Don't write to inferior_ptid in aix-thread.c
There are other writes in the file, but they seem more harmless. This one is changing the current thread permanently. Untested. gdb/ChangeLog: yyyy-mm-dd Pedro Alves <palves@redhat.com> * aix-thread.c (pd_update): Use switch_to_thread.
-rw-r--r--gdb/aix-thread.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/aix-thread.c b/gdb/aix-thread.c
index f2bd05fef22..3963a08c840 100644
--- a/gdb/aix-thread.c
+++ b/gdb/aix-thread.c
@@ -902,7 +902,7 @@ pd_update (int set_infpid)
{
ptid = thread->ptid;
if (set_infpid)
- inferior_ptid = ptid;
+ switch_to_thread (thread);
}
return ptid;
}