summaryrefslogtreecommitdiff
path: root/sys/compat/linux/common/linux_exec.c
diff options
context:
space:
mode:
authormanu <manu@NetBSD.org>2001-03-15 19:18:20 +0000
committermanu <manu@NetBSD.org>2001-03-15 19:18:20 +0000
commit1208df7bdf22a8729c588252ec82820fe3387d5a (patch)
tree2309135fda60c5d0be7791e7434eb8a352fbff3f /sys/compat/linux/common/linux_exec.c
parent8c5e25e4869110a80263c49b3b7a8e7fdaf2fd8e (diff)
Fixed brk() emulation. We now keep track of the processes' idea of the
break value. See http://mail-index.netbsd.org/tech-kern/2001/03/15/0000.html for more details.
Diffstat (limited to 'sys/compat/linux/common/linux_exec.c')
-rw-r--r--sys/compat/linux/common/linux_exec.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/compat/linux/common/linux_exec.c b/sys/compat/linux/common/linux_exec.c
index 4a7170f0d27..37a5b9a0a1b 100644
--- a/sys/compat/linux/common/linux_exec.c
+++ b/sys/compat/linux/common/linux_exec.c
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_exec.c,v 1.45 2001/01/19 01:44:46 manu Exp $ */
+/* $NetBSD: linux_exec.c,v 1.46 2001/03/15 19:18:20 manu Exp $ */
/*-
* Copyright (c) 1994, 1995, 1998, 2000 The NetBSD Foundation, Inc.
@@ -149,6 +149,10 @@ linux_e_proc_exec(p, epp)
}
memset(p->p_emuldata, '\0', sizeof(struct linux_emuldata));
+
+ /* Set the process idea of the break to the real value */
+ ((struct linux_emuldata*)(p->p_emuldata))->p_break =
+ p->p_vmspace->vm_daddr + ctob(p->p_vmspace->vm_dsize);
}
/*