summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_fork.c
diff options
context:
space:
mode:
authorjulian <julian@FreeBSD.org>2004-07-18 23:36:13 +0000
committerjulian <julian@FreeBSD.org>2004-07-18 23:36:13 +0000
commita488bebcd21f1e39697ac09fdac970a06d6fb621 (patch)
tree548243b8828b679ca121764ef843b623c31cf5b9 /sys/kern/kern_fork.c
parentd538dc62fd30a8ac9beb2f57ffc4321e42569aab (diff)
downloadFreeBSD-src-a488bebcd21f1e39697ac09fdac970a06d6fb621.zip
FreeBSD-src-a488bebcd21f1e39697ac09fdac970a06d6fb621.tar.gz
When calling scheduler entrypoints for creating new threads and processes,
specify "us" as the thread not the process/ksegrp/kse. You can always find the others from the thread but the converse is not true. Theorotically this would lead to runtime being allocated to the wrong entity in some cases though it is not clear how often this actually happenned. (would only affect threaded processes and would probably be pretty benign, but it WAS a bug..) Reviewed by: peter
Diffstat (limited to 'sys/kern/kern_fork.c')
-rw-r--r--sys/kern/kern_fork.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/kern_fork.c b/sys/kern/kern_fork.c
index 7a9f234..e42a436 100644
--- a/sys/kern/kern_fork.c
+++ b/sys/kern/kern_fork.c
@@ -515,7 +515,7 @@ again:
* Allow the scheduler to adjust the priority of the child and
* parent while we hold the sched_lock.
*/
- sched_fork(p1, p2);
+ sched_fork(td, p2);
mtx_unlock_spin(&sched_lock);
p2->p_ucred = crhold(td->td_ucred);
OpenPOWER on IntegriCloud