diff options
author | Eric Wong <normalperson@yhbt.net> | 2011-04-21 21:22:06 +0000 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2011-04-21 21:41:50 +0000 |
commit | e5c4125c348104444714b5111c90016d520461d6 (patch) | |
tree | 915cb4ec3668d3e7249dc41055f74ed5f4000117 /lib | |
parent | 71d48a01a7c257dffa22c10781c55deff64037d2 (diff) | |
download | rainbows-e5c4125c348104444714b5111c90016d520461d6.tar.gz |
Thread-switching sometimes takes too long under YARV, so we force a switch since the watchdog thread is lower-priority.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/rainbows/thread_timeout.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rainbows/thread_timeout.rb b/lib/rainbows/thread_timeout.rb index 44baf9a..3d28daf 100644 --- a/lib/rainbows/thread_timeout.rb +++ b/lib/rainbows/thread_timeout.rb @@ -93,7 +93,7 @@ class Rainbows::ThreadTimeout sleep(@timeout) else sec = next_expiry - Time.now - sec > 0.0 ? sleep(sec) : Thread.pass + sec > 0.0 ? sleep(sec) : Thread.pass # give other threads a chance end rescue => e logger.error e |