Fix powerpc-power8.exp test with new mnemonics
[deliverable/binutils-gdb.git] / gdb / target.c
index 1f0741471d829294ddbbca17c55ac564908b305e..6babfc562563d6d09dddcbb955ecaa11a9171fb6 100644 (file)
@@ -872,7 +872,7 @@ The first argument is the type or protocol of the target machine.\n\
 Remaining arguments are interpreted by the target protocol.  For more\n\
 information on the arguments for a particular protocol, type\n\
 `help target ' followed by the protocol name."),
-                         &targetlist, "target ", 0, &cmdlist);
+                         &targetlist, 0, &cmdlist);
   c = add_cmd (t.shortname, no_class, t.doc, &targetlist);
   set_cmd_context (c, (void *) &t);
   set_cmd_sfunc (c, open_target);
@@ -1214,7 +1214,7 @@ target_stack::unpush (target_ops *t)
   m_stack[stratum] = NULL;
 
   if (m_top == stratum)
-    m_top = t->beneath ()->stratum ();
+    m_top = this->find_beneath (t)->stratum ();
 
   /* Finally close the target, if there are no inferiors
      referencing this target still.  Note we do this after unchaining,
@@ -2718,12 +2718,14 @@ target_follow_fork (bool follow_child, bool detach_fork)
   return target->follow_fork (follow_child, detach_fork);
 }
 
-/* Target wrapper for follow exec hook.  */
+/* See target.h.  */
 
 void
-target_follow_exec (struct inferior *inf, const char *execd_pathname)
+target_follow_exec (inferior *follow_inf, ptid_t ptid,
+                   const char *execd_pathname)
 {
-  current_inferior ()->top_target ()->follow_exec (inf, execd_pathname);
+  current_inferior ()->top_target ()->follow_exec (follow_inf, ptid,
+                                                  execd_pathname);
 }
 
 static void
@@ -3734,7 +3736,8 @@ debug_target::info () const
 void
 target_close (struct target_ops *targ)
 {
-  gdb_assert (!current_inferior ()->target_is_pushed (targ));
+  for (inferior *inf : all_inferiors ())
+    gdb_assert (!inf->target_is_pushed (targ));
 
   fileio_handles_invalidate_target (targ);
 
This page took 0.025803 seconds and 4 git commands to generate.