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

* test/ruby/test_continuation.rb (tracing_with_set_trace_func): don't

call Continuation from other threads. [ruby-dev:45596] [Bug #6382]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35498 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nagachika 2012-04-30 14:09:36 +00:00
parent 860cf7b812
commit c40e6f8257
2 changed files with 10 additions and 2 deletions

View file

@ -1,3 +1,8 @@
Mon Apr 30 23:05:53 2012 CHIKANAGA Tomoyuki <nagachika00@gmail.com>
* test/ruby/test_continuation.rb (tracing_with_set_trace_func): don't
call Continuation from other threads. [ruby-dev:45596] [Bug #6382]
Mon Apr 30 21:09:06 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
* configure.in (optflags): disable unsafe optimizations.

View file

@ -78,10 +78,13 @@ class TestContinuation < Test::Unit::TestCase
end
def tracing_with_set_trace_func
orig_thread = Thread.current
cont = nil
func = lambda do |*args|
@memo += 1
cont.call(nil)
if orig_thread == Thread.current
@memo += 1
cont.call(nil)
end
end
cont = callcc { |cc| cc }
if cont