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

misplaced rescue

* test/ruby/test_thread.rb (test_condvar_wait_deadlock_2): fix cleanup
  code which is never executed because of misplaced rescue.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35187 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2012-03-31 00:48:56 +00:00
parent 197627354e
commit d481e34e3c

View file

@ -158,8 +158,9 @@ class TestThread < Test::Unit::TestCase
assert_raise(Timeout::Error) do
Timeout.timeout(0.1) { condvar.wait mutex }
end
mutex.unlock rescue
threads[i].each.join
mutex.unlock
threads.each(&:kill)
threads.each(&:join)
end
def test_condvar_timed_wait