Set inferior_ptid in ravenscar_thread_target::update_thread_list
authorTom Tromey <tromey@adacore.com>
Fri, 7 Aug 2020 16:26:45 +0000 (10:26 -0600)
committerTom Tromey <tromey@adacore.com>
Fri, 7 Aug 2020 16:26:47 +0000 (10:26 -0600)
commit0e29517d97e94bfceb3abce77aea3b249f6cdaf3
tree6f7956483aa993b5d68f6f3722911d454401b23f
parent592f9bd76a1a9888eb95eff24048c12ca2c1f332
Set inferior_ptid in ravenscar_thread_target::update_thread_list

Commit 2da4b788f ("Don't write to inferior_ptid in
ravenscar-thread.c") caused a Ravenscar regression (which, FWIW, is
understandable because Ravenscar is difficult to test).  Namely,
ravenscar_thread_target::update_thread_list calls
iterate_over_live_ada_tasks, which calls ada_build_task_list, which
uses target_has_stack -- which relies on inferior_ptid.

This patch changes update_thread_list to ensure that inferior_ptid is
set before making this call.  This avoids various failures on
Ravenscar targets.

gdb/ChangeLog
2020-08-07  Tom Tromey  <tromey@adacore.com>

* ravenscar-thread.c (update_thread_list): Set inferior_ptid.
gdb/ChangeLog
gdb/ravenscar-thread.c