mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-18 14:23:55 +00:00
MFp4 (112893):
Make linux_vfork() actually work. This enables make to work again with 2.6. It also fixes the LTP vfork tests. Submitted by: rdivacky
This commit is contained in:
parent
31becc7692
commit
973ac082f8
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=166007
|
@ -497,6 +497,7 @@ linux_vfork(struct thread *td, struct linux_vfork_args *args)
|
|||
return (error);
|
||||
/* wait for the children to exit, ie. emulate vfork */
|
||||
PROC_LOCK(p2);
|
||||
p2->p_flag |= P_PPWAIT;
|
||||
while (p2->p_flag & P_PPWAIT)
|
||||
msleep(td->td_proc, &p2->p_mtx, PWAIT, "ppwait", 0);
|
||||
PROC_UNLOCK(p2);
|
||||
|
|
|
@ -341,6 +341,7 @@ linux_vfork(struct thread *td, struct linux_vfork_args *args)
|
|||
return (error);
|
||||
/* wait for the children to exit, ie. emulate vfork */
|
||||
PROC_LOCK(p2);
|
||||
p2->p_flag |= P_PPWAIT;
|
||||
while (p2->p_flag & P_PPWAIT)
|
||||
msleep(td->td_proc, &p2->p_mtx, PWAIT, "ppwait", 0);
|
||||
PROC_UNLOCK(p2);
|
||||
|
|
Loading…
Reference in a new issue