diff options
author | davidxu <davidxu@FreeBSD.org> | 2006-07-13 06:35:43 +0000 |
---|---|---|
committer | davidxu <davidxu@FreeBSD.org> | 2006-07-13 06:35:43 +0000 |
commit | 19b84189035f11be93ba57379660d66d24d77c2b (patch) | |
tree | a578a4c69968927b0ae5c15efa30827ff9d1c6ef /lib/libthr/thread/thr_create.c | |
parent | bde285ca74095822da08a85bc8bc403964bd1036 (diff) | |
download | FreeBSD-src-19b84189035f11be93ba57379660d66d24d77c2b.zip FreeBSD-src-19b84189035f11be93ba57379660d66d24d77c2b.tar.gz |
Use thr_setscheduler, thr_getscheduler and thr_setschedparam to implement
pthread functions.
Diffstat (limited to 'lib/libthr/thread/thr_create.c')
-rw-r--r-- | lib/libthr/thread/thr_create.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libthr/thread/thr_create.c b/lib/libthr/thread/thr_create.c index e74278d..49e9b45 100644 --- a/lib/libthr/thread/thr_create.c +++ b/lib/libthr/thread/thr_create.c @@ -144,9 +144,10 @@ _pthread_create(pthread_t * thread, const pthread_attr_t * attr, if (new_thread->attr.flags & PTHREAD_SCOPE_SYSTEM) param.flags |= THR_SYSTEM_SCOPE; if (new_thread->attr.sched_inherit == PTHREAD_INHERIT_SCHED) - param.sched = NULL; + param.sched_param = NULL; else { - param.sched = &sched_param; + param.sched_param = &sched_param; + param.sched_param_size = sizeof(sched_param); sched_param.policy = new_thread->attr.sched_policy; sched_param.param.sched_priority = new_thread->attr.prio; } |