Consolidate target_mourn_inferior between GDB and gdbserver
[deliverable/binutils-gdb.git] / gdb / gdbserver / server.c
index 3ec585cfb6bb6130dcb4a295c59cec33315c3a0b..2996e19be29c3d4ab04d5c8d6f966e46b68c6ef6 100644 (file)
@@ -297,7 +297,7 @@ start_inferior (char **argv)
       current_thread->last_status = last_status;
     }
   else
-    mourn_inferior (find_process_pid (ptid_get_pid (last_ptid)));
+    target_mourn_inferior (last_ptid);
 
   return signal_pid;
 }
@@ -2779,7 +2779,7 @@ resume (struct thread_resume *actions, size_t num_actions)
 
       if (last_status.kind == TARGET_WAITKIND_EXITED
           || last_status.kind == TARGET_WAITKIND_SIGNALLED)
-        mourn_inferior (find_process_pid (ptid_get_pid (last_ptid)));
+        target_mourn_inferior (last_ptid);
     }
 }
 
@@ -4392,7 +4392,7 @@ handle_target_event (int err, gdb_client_data client_data)
          || last_status.kind == TARGET_WAITKIND_SIGNALLED)
        {
          mark_breakpoints_out (process);
-         mourn_inferior (process);
+         target_mourn_inferior (last_ptid);
        }
       else if (last_status.kind == TARGET_WAITKIND_THREAD_EXITED)
        ;
This page took 0.024076 seconds and 4 git commands to generate.