aboutsummaryrefslogtreecommitdiff
path: root/sim/bpf/sim-if.c
diff options
context:
space:
mode:
Diffstat (limited to 'sim/bpf/sim-if.c')
-rw-r--r--sim/bpf/sim-if.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sim/bpf/sim-if.c b/sim/bpf/sim-if.c
index 7503a30..6d2f672 100644
--- a/sim/bpf/sim-if.c
+++ b/sim/bpf/sim-if.c
@@ -21,6 +21,7 @@
#include <stdlib.h>
+#include "sim/callback.h"
#include "sim-main.h"
#include "sim-options.h"
#include "libiberty.h"
@@ -193,6 +194,7 @@ sim_create_inferior (SIM_DESC sd, struct bfd *abfd,
char *const *argv, char *const *env)
{
SIM_CPU *current_cpu = STATE_CPU (sd, 0);
+ host_callback *cb = STATE_CALLBACK (sd);
SIM_ADDR addr;
/* Determine the start address.
@@ -219,5 +221,8 @@ sim_create_inferior (SIM_DESC sd, struct bfd *abfd,
STATE_PROG_ENVP (sd) = dupargv (env);
}
+ cb->argv = STATE_PROG_ARGV (sd);
+ cb->envp = STATE_PROG_ENVP (sd);
+
return SIM_RC_OK;
}