diff options
| author | Marcel Moolenaar <marcel@FreeBSD.org> | 1999-08-28 20:45:08 +0000 |
|---|---|---|
| committer | Marcel Moolenaar <marcel@FreeBSD.org> | 1999-08-28 20:45:08 +0000 |
| commit | db10c0d8b73d4826ddea36a32eb531b14f76c52d (patch) | |
| tree | 3222abcfac9711f9bf52e4e7f8b012bd35b6002f /sys/i386/linux/linux_misc.c | |
| parent | 23d164ceb8f379122304971a8c70a5716914125a (diff) | |
Notes
Diffstat (limited to 'sys/i386/linux/linux_misc.c')
| -rw-r--r-- | sys/i386/linux/linux_misc.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/sys/i386/linux/linux_misc.c b/sys/i386/linux/linux_misc.c index 6ff7a5ad9e7a..6cda44b67414 100644 --- a/sys/i386/linux/linux_misc.c +++ b/sys/i386/linux/linux_misc.c @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: linux_misc.c,v 1.51.2.4 1999/08/17 13:16:55 marcel Exp $ + * $Id: linux_misc.c,v 1.51.2.5 1999/08/17 21:06:04 marcel Exp $ */ #include "opt_compat.h" @@ -571,6 +571,25 @@ linux_fork(struct proc *p, struct linux_fork_args *args) return 0; } +int +linux_vfork(p, args) + struct proc *p; + struct linux_vfork_args *args; +{ + int error; + +#ifdef DEBUG + printf("Linux-emul(%ld): vfork()\n", (long)p->p_pid); +#endif + + if ((error = vfork(p, (struct vfork_args *)args)) != 0) + return error; + /* Are we the child? */ + if (p->p_retval[1] == 1) + p->p_retval[0] = 0; + return 0; +} + #define CLONE_VM 0x100 #define CLONE_FS 0x200 #define CLONE_FILES 0x400 |
