aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/kern_kthread.c
diff options
context:
space:
mode:
authorJulian Elischer <julian@FreeBSD.org>2008-04-29 22:43:15 +0000
committerJulian Elischer <julian@FreeBSD.org>2008-04-29 22:43:15 +0000
commitc59b9a7659c40e21fdf2578bb53d9ac02129899f (patch)
tree2f3e7b3009aceecd164d6b62d362032641e0f4a8 /sys/kern/kern_kthread.c
parenta8f7b90ca0bc8dbf4bc76ee775b90671998b559b (diff)
downloadsrc-c59b9a7659c40e21fdf2578bb53d9ac02129899f.tar.gz
src-c59b9a7659c40e21fdf2578bb53d9ac02129899f.zip
Notes
Diffstat (limited to 'sys/kern/kern_kthread.c')
-rw-r--r--sys/kern/kern_kthread.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/kern_kthread.c b/sys/kern/kern_kthread.c
index 18f16727faae..baa154019237 100644
--- a/sys/kern/kern_kthread.c
+++ b/sys/kern/kern_kthread.c
@@ -403,7 +403,8 @@ kproc_kthread_add(void (*func)(void *), void *arg,
if (error)
return (error);
td = FIRST_THREAD_IN_PROC(*procptr);
- *tdptr = td;
+ if (tdptr)
+ *tdptr = td;
va_start(ap, fmt);
vsnprintf(td->td_name, sizeof(td->td_name), fmt, ap);
va_end(ap);