summaryrefslogtreecommitdiff
path: root/bootstraptest
diff options
context:
space:
mode:
Diffstat (limited to 'bootstraptest')
-rw-r--r--bootstraptest/test_thread.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/bootstraptest/test_thread.rb b/bootstraptest/test_thread.rb
index 5fd1d18e96..446c9ff4d2 100644
--- a/bootstraptest/test_thread.rb
+++ b/bootstraptest/test_thread.rb
@@ -393,9 +393,14 @@ assert_equal 'ok', %{
m = Mutex.new
Thread.new { m.lock; sleep 1 }
sleep 0.3
+ parent = Thread.current
Thread.new do
sleep 0.3
- fork { GC.start }
+ begin
+ fork { GC.start }
+ rescue Exception
+ parent.raise $!
+ end
end
m.lock
pid, status = Process.wait2