summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
Diffstat (limited to 'linux')
-rw-r--r--linux/kthread.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/linux/kthread.c b/linux/kthread.c
index 65e824b4..41bfca2f 100644
--- a/linux/kthread.c
+++ b/linux/kthread.c
@@ -80,7 +80,7 @@ struct task_struct *kthread_create(int (*thread_fn)(void *data),
ret = pthread_create(&p->thread, &attr, kthread_start_fn, p);
if (ret)
- die("pthread_create error %s", strerror(ret));
+ return ERR_PTR(-ret);
pthread_setname_np(p->thread, p->comm);
return p;
}