aboutsummaryrefslogtreecommitdiff
path: root/gdb/remote-sim.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/remote-sim.c')
-rw-r--r--gdb/remote-sim.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/remote-sim.c b/gdb/remote-sim.c
index c7208b0..d0f0f50 100644
--- a/gdb/remote-sim.c
+++ b/gdb/remote-sim.c
@@ -217,11 +217,12 @@ gdbsim_open (args, from_tty)
{
if (sr_get_debug ())
printf_filtered ("gdbsim_open: args \"%s\"\n", args ? args : "(null)");
- sim_open (args);
sim_set_callbacks (&default_callback);
default_callback.init (&default_callback);
+ sim_open (args);
+
push_target (&gdbsim_ops);
target_fetch_registers (-1);
printf_filtered ("Connected to the simulator.\n");