kern_fork.c (1542) | kern_fork.c (1549) |
---|---|
1/* 2 * Copyright (c) 1982, 1986, 1989, 1991, 1993 3 * The Regents of the University of California. All rights reserved. 4 * (c) UNIX System Laboratories, Inc. 5 * All or some portions of this file are derived from material licensed 6 * to the University of California by American Telephone and Telegraph 7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with 8 * the permission of UNIX System Laboratories, Inc. --- 41 unchanged lines hidden (view full) --- 50#include <sys/file.h> 51#include <sys/acct.h> 52#include <sys/ktrace.h> 53 54struct fork_args { 55 int dummy; 56}; 57/* ARGSUSED */ | 1/* 2 * Copyright (c) 1982, 1986, 1989, 1991, 1993 3 * The Regents of the University of California. All rights reserved. 4 * (c) UNIX System Laboratories, Inc. 5 * All or some portions of this file are derived from material licensed 6 * to the University of California by American Telephone and Telegraph 7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with 8 * the permission of UNIX System Laboratories, Inc. --- 41 unchanged lines hidden (view full) --- 50#include <sys/file.h> 51#include <sys/acct.h> 52#include <sys/ktrace.h> 53 54struct fork_args { 55 int dummy; 56}; 57/* ARGSUSED */ |
58int |
|
58fork(p, uap, retval) 59 struct proc *p; 60 struct fork_args *uap; 61 int retval[]; 62{ 63 64 return (fork1(p, 0, retval)); 65} 66 67/* ARGSUSED */ | 59fork(p, uap, retval) 60 struct proc *p; 61 struct fork_args *uap; 62 int retval[]; 63{ 64 65 return (fork1(p, 0, retval)); 66} 67 68/* ARGSUSED */ |
69int |
|
68vfork(p, uap, retval) 69 struct proc *p; 70 struct fork_args *uap; 71 int retval[]; 72{ 73 74 return (fork1(p, 1, retval)); 75} 76 77int nprocs = 1; /* process 0 */ 78 | 70vfork(p, uap, retval) 71 struct proc *p; 72 struct fork_args *uap; 73 int retval[]; 74{ 75 76 return (fork1(p, 1, retval)); 77} 78 79int nprocs = 1; /* process 0 */ 80 |
81int |
|
79fork1(p1, isvfork, retval) 80 register struct proc *p1; 81 int isvfork, retval[]; 82{ 83 register struct proc *p2; 84 register uid_t uid; 85 struct proc *newproc; 86 struct proc **hash; --- 229 unchanged lines hidden --- | 82fork1(p1, isvfork, retval) 83 register struct proc *p1; 84 int isvfork, retval[]; 85{ 86 register struct proc *p2; 87 register uid_t uid; 88 struct proc *newproc; 89 struct proc **hash; --- 229 unchanged lines hidden --- |