summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorThorsten Lockert <tholo@cvs.openbsd.org>2001-02-02 05:21:48 +0000
committerThorsten Lockert <tholo@cvs.openbsd.org>2001-02-02 05:21:48 +0000
commit47925fc05ff6b8b009de1100cb4546f158b67e63 (patch)
tree2a367d43445cef5a55fe16b91393339cfeacc084 /sys
parent7cbff969e63386248de04c8ffeb65ef022f047a2 (diff)
Correct setup for running ELF binaries from FreeBSD; ok deraadt@
Diffstat (limited to 'sys')
-rw-r--r--sys/compat/freebsd/freebsd_exec.c6
-rw-r--r--sys/compat/freebsd/freebsd_exec.h4
2 files changed, 6 insertions, 4 deletions
diff --git a/sys/compat/freebsd/freebsd_exec.c b/sys/compat/freebsd/freebsd_exec.c
index 350b9612031..9cc2371d228 100644
--- a/sys/compat/freebsd/freebsd_exec.c
+++ b/sys/compat/freebsd/freebsd_exec.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: freebsd_exec.c,v 1.8 1999/11/10 15:55:20 mickey Exp $ */
+/* $OpenBSD: freebsd_exec.c,v 1.9 2001/02/02 05:21:47 tholo Exp $ */
/* $NetBSD: freebsd_exec.c,v 1.2 1996/05/18 16:02:08 christos Exp $ */
/*
@@ -87,8 +87,8 @@ struct emul emul_elf_freebsd = {
#else
NULL,
#endif
- 0,
- copyargs,
+ FREEBSD_ELF_AUX_ARGSIZ,
+ elf_copyargs,
setregs,
NULL,
freebsd_sigcode,
diff --git a/sys/compat/freebsd/freebsd_exec.h b/sys/compat/freebsd/freebsd_exec.h
index da8e3e50fde..a01035f6312 100644
--- a/sys/compat/freebsd/freebsd_exec.h
+++ b/sys/compat/freebsd/freebsd_exec.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: freebsd_exec.h,v 1.3 1999/02/10 08:07:19 deraadt Exp $ */
+/* $OpenBSD: freebsd_exec.h,v 1.4 2001/02/02 05:21:47 tholo Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -92,6 +92,8 @@
/* String table offset. */
#define FREEBSD_N_STROFF(ex) (FREEBSD_N_SYMOFF(ex) + (ex).a_syms)
+#define FREEBSD_ELF_AUX_ARGSIZ (sizeof(AuxInfo) * 15 / sizeof(char *))
+
#define FREEBSD_AOUT_HDR_SIZE sizeof(struct exec)
int exec_freebsd_aout_makecmds __P((struct proc *, struct exec_package *));