Enable 'set print inferior-events' and improve detach/fork/kill/exit messages
[deliverable/binutils-gdb.git] / gdb / infcmd.c
index d43e7f202d39fd64f4e71d001484cb1e634e211b..6c9f885badd7943baa8296772a886d610967590f 100644 (file)
@@ -2595,8 +2595,16 @@ kill_command (const char *arg, int from_tty)
     error (_("The program is not being run."));
   if (!query (_("Kill the program being debugged? ")))
     error (_("Not confirmed."));
+
+  std::string pid_str = target_pid_to_str (inferior_ptid);
+  int infnum = current_inferior ()->num;
+
   target_kill ();
 
+  if (print_inferior_events)
+    printf_unfiltered (_("[Inferior %d (%s) has been killed]\n"),
+                      infnum, pid_str.c_str ());
+
   /* If we still have other inferiors to debug, then don't mess with
      with their threads.  */
   if (!have_inferiors ())
This page took 0.025871 seconds and 4 git commands to generate.