From e8f67573e292b5e12ff36b062c068c43f1ff1fe6 Mon Sep 17 00:00:00 2001 From: mycroft Date: Wed, 22 Feb 1995 01:39:56 +0000 Subject: [PATCH] Align the stack even if envp is NULL. --- sys/kern/kern_exec.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c index ed85f2ce3774..7ad4557d4325 100644 --- a/sys/kern/kern_exec.c +++ b/sys/kern/kern_exec.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_exec.c,v 1.60 1995/02/04 14:44:48 mycroft Exp $ */ +/* $NetBSD: kern_exec.c,v 1.61 1995/02/22 01:39:56 mycroft Exp $ */ /*- * Copyright (C) 1993, 1994 Christopher G. Demetriou @@ -330,9 +330,10 @@ execve(p, uap, retval) cpp++; envc++; } - dp = (char *) ALIGN(dp); } + dp = (char *) ALIGN(dp); + /* Now check if args & environ fit into new stack */ len = ((argc + envc + 2 + pack.ep_setup_arglen) * sizeof(char *) + sizeof(int) + dp + STACKGAPLEN + szsigcode +