summaryrefslogtreecommitdiff
path: root/thread.c
diff options
context:
space:
mode:
authorkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-04 16:06:43 +0000
committerkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-04 16:06:43 +0000
commit70d603a41274c873183abcfb83dabfcaa3caf95c (patch)
treee8e096bc408fb8456bd9307536e25e20e2f5244e /thread.c
parent3765f668c616c1ef2b8d4feb9195fb2c62e96c3d (diff)
supress warning
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38190 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread.c')
-rw-r--r--thread.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/thread.c b/thread.c
index a4b6d97669..1005a89793 100644
--- a/thread.c
+++ b/thread.c
@@ -4202,7 +4202,7 @@ rb_mutex_lock(VALUE self)
while (mutex->th != th) {
int interrupted;
enum rb_thread_status prev_status = th->status;
- int timeout_ms = 0;
+ volatile int timeout_ms = 0;
struct rb_unblock_callback oldubf;
set_unblock_function(th, lock_interrupt, mutex, &oldubf, FALSE);
@@ -4223,7 +4223,7 @@ rb_mutex_lock(VALUE self)
}
GVL_UNLOCK_BEGIN();
- interrupted = lock_func(th, mutex, timeout_ms);
+ interrupted = lock_func(th, mutex, (int)timeout_ms);
native_mutex_unlock(&mutex->lock);
GVL_UNLOCK_END();