1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* thread_pthread.c (native_thread_apply_priority):

fix argument range check.  [ruby-dev:33124]



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16481 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
ko1 2008-05-19 12:09:14 +00:00
parent 3c95aacfcb
commit 67d0fbd03f
2 changed files with 9 additions and 4 deletions

View file

@ -1,3 +1,8 @@
Mon May 19 21:07:48 2008 Koichi Sasada <ko1@atdot.net>
* thread_pthread.c (native_thread_apply_priority):
fix argument range check. [ruby-dev:33124]
Mon May 19 18:22:35 2008 Akinori MUSHA <knu@iDaemons.org>
* ext/openssl/ossl_pkcs5.c (ossl_pkcs5_pbkdf2_hmac): Fix the type

View file

@ -358,12 +358,12 @@ native_thread_apply_priority(rb_thread_t *th)
max = sched_get_priority_max(policy);
min = sched_get_priority_min(policy);
if (min < priority) {
priority = max;
}
else if (max > priority) {
if (min > priority) {
priority = min;
}
else if (max < priority) {
priority = max;
}
sp.sched_priority = priority;
pthread_setschedparam(th->thread_id, policy, &sp);