#include "i386-nat.h"
#include "inferior.h"
+#include "infrun.h"
#include "gdbthread.h"
#include "gdb_wait.h"
#include "gdbcore.h"
{GDB_SIGNAL_LAST, -1}
};
-static void
-go32_open (char *name, int from_tty)
-{
- printf_unfiltered ("Done. Use the \"run\" command to run the program.\n");
-}
-
static void
go32_attach (struct target_ops *ops, char *args, int from_tty)
{
inf = current_inferior ();
inferior_appeared (inf, SOME_PID);
- push_target (ops);
+ if (!target_is_pushed (ops))
+ push_target (ops);
add_thread_silent (inferior_ptid);
delete_thread_silent (ptid);
prog_has_started = 0;
- unpush_target (ops);
generic_mourn_inferior ();
+ inf_child_maybe_unpush_target (ops);
}
/* Hardware watchpoint support. */
{
struct target_ops *t = inf_child_target ();
- t->to_open = go32_open;
t->to_attach = go32_attach;
t->to_resume = go32_resume;
t->to_wait = go32_wait;