ptid = ptid_t (pid, lwpid, 0);
- add_thread (ptid);
+ add_thread (inf->process_target (), ptid);
/* Warning, Will Robinson, looking at BFD private data! */
{
inferior_appeared (current_inferior (), CORELOW_PID);
inferior_ptid = ptid_t (CORELOW_PID);
- add_thread_silent (inferior_ptid);
+ add_thread_silent (target, inferior_ptid);
}
else
switch_to_thread (thread);
/* Current thread should be NUM 1 but the user does not know that.
If a program is single threaded gdb in general does not mention
anything about threads. That is why the test is >= 2. */
- if (thread_count () >= 2)
+ if (thread_count (target) >= 2)
{
try
{
/* Otherwise, this isn't a "threaded" core -- use the PID field, but
only if it isn't a fake PID. */
- inf = find_inferior_ptid (ptid);
+ inf = find_inferior_ptid (this, ptid);
if (inf != NULL && !inf->fake_pid_p)
return normal_pid_to_str (ptid);