From 19687171365b09d5fce7e5a993334924731e4d98 Mon Sep 17 00:00:00 2001 From: usa Date: Thu, 19 Nov 2009 00:56:44 +0000 Subject: [PATCH] * test_thread.rb: DO NOT USE FORK WITHOUT RESCUE. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25850 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- bootstraptest/test_thread.rb | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/bootstraptest/test_thread.rb b/bootstraptest/test_thread.rb index e463626167..5fd1d18e96 100644 --- a/bootstraptest/test_thread.rb +++ b/bootstraptest/test_thread.rb @@ -420,10 +420,13 @@ assert_finish 3, %q{ end end - pid = fork do - # Child - STDOUT.write "This is the child process.\n" - STDOUT.write "Child process exiting.\n" + begin + pid = fork do + # Child + STDOUT.write "This is the child process.\n" + STDOUT.write "Child process exiting.\n" + end + Process.waitpid(pid) + rescue NotImplementedError end - Process.waitpid(pid) }, '[ruby-core:26361]'