diff options
Diffstat (limited to 'sys/kern/exec_elf.c')
-rw-r--r-- | sys/kern/exec_elf.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/kern/exec_elf.c b/sys/kern/exec_elf.c index efa3f04e3f4..a5430d47328 100644 --- a/sys/kern/exec_elf.c +++ b/sys/kern/exec_elf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: exec_elf.c,v 1.11 1996/06/15 07:30:05 etheisen Exp $ */ +/* $OpenBSD: exec_elf.c,v 1.12 1996/06/16 20:05:08 etheisen Exp $ */ /* $NetBSD: exec_elf.c,v 1.6 1996/02/09 18:59:18 christos Exp $ */ /* @@ -377,7 +377,8 @@ elf_load_file(p, path, vcset, entry, ap, last) /* If entry is within this section it must be text */ if (eh.e_entry >= ph[i].p_vaddr && eh.e_entry < (ph[i].p_vaddr + size)) { - *entry = addr + eh.e_entry - ph[i].p_vaddr; + *entry = addr + eh.e_entry - + ELF_ALIGN(ph[i].p_vaddr,ph[i].p_align); ap->arg_interp = addr; } addr += size; |