diff options
Diffstat (limited to 'bsd-user/main.c')
-rw-r--r-- | bsd-user/main.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/bsd-user/main.c b/bsd-user/main.c index 39c4a0f33c..1388c7a13d 100644 --- a/bsd-user/main.c +++ b/bsd-user/main.c @@ -343,6 +343,7 @@ int main(int argc, char **argv) const char *log_mask = NULL; struct target_pt_regs regs1, *regs = ®s1; struct image_info info1, *info = &info1; + struct bsd_binprm bprm; TaskState ts1, *ts = &ts1; CPUArchState *env; CPUState *cpu; @@ -499,6 +500,9 @@ int main(int argc, char **argv) /* Zero out regs */ memset(regs, 0, sizeof(struct target_pt_regs)); + /* Zero bsd params */ + memset(&bprm, 0, sizeof(bprm)); + /* Zero out image_info */ memset(info, 0, sizeof(struct image_info)); @@ -566,7 +570,8 @@ int main(int argc, char **argv) } } - if (loader_exec(filename, argv + optind, target_environ, regs, info) != 0) { + if (loader_exec(filename, argv + optind, target_environ, regs, info, + &bprm) != 0) { printf("Error loading %s\n", filename); _exit(1); } |