aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMateusz Guzik <mjg@FreeBSD.org>2015-06-10 15:34:43 +0000
committerMateusz Guzik <mjg@FreeBSD.org>2015-06-10 15:34:43 +0000
commit6871c7c3f134b2959f9267447ef42a8adf48fef2 (patch)
tree0b329c0cf4ca27c2a28ba8660bc491ea8a3c7c41 /sys
parentebe071e56a1e7f4f8970bd364182b362af74186e (diff)
downloadsrc-6871c7c3f134b2959f9267447ef42a8adf48fef2.tar.gz
src-6871c7c3f134b2959f9267447ef42a8adf48fef2.zip
linux: make sure to grab all cow structs when creating a thread
This is a fixup for r284214. Reported and tested by: Ivan Klymenko <fidaj ukr.net>
Notes
Notes: svn path=/head/; revision=284226
Diffstat (limited to 'sys')
-rw-r--r--sys/compat/linux/linux_fork.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/compat/linux/linux_fork.c b/sys/compat/linux/linux_fork.c
index 0fd47fdd26fb..394c26fffa5f 100644
--- a/sys/compat/linux/linux_fork.c
+++ b/sys/compat/linux/linux_fork.c
@@ -298,7 +298,7 @@ linux_clone_thread(struct thread *td, struct linux_clone_args *args)
__rangeof(struct thread, td_startcopy, td_endcopy));
newtd->td_proc = p;
- newtd->td_ucred = crhold(td->td_ucred);
+ thread_cow_get(newtd, td);
/* create the emuldata */
linux_proc_init(td, newtd, args->flags);