From 526a853d6d6dbc126aa1e7ab113fc72a481c081c Mon Sep 17 00:00:00 2001 From: nagachika Date: Sun, 13 May 2012 14:50:49 +0000 Subject: [PATCH] * test/ruby/test_io.rb (test_flush_in_finalizer1): don't use IO.for_fd to close IO objects. it create IO object with already closed fd, and cause occasional Errno::EBADF in following tests. [ruby-core:45020] [Bug #6228] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35637 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 9 ++++++++- test/ruby/test_io.rb | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index a4f0a473bd..06de6f3b59 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,11 @@ -Sun May 13 23:32:16 2012 CHIKANAGA Tomoyuki +Sun May 13 23:38:31 2012 CHIKANAGA Tomoyuki + + * test/ruby/test_io.rb (test_flush_in_finalizer1): don't use IO.for_fd + to close IO objects. it create IO object with already closed fd, and + cause occasional Errno::EBADF in following tests. [ruby-core:45020] + [Bug #6228] + +Sun May 13 23:32:16 2012 CHIKANAGA Tomoyuki * test/ruby/test_io.rb (TestIO): revert r35631. it broke the intent of test_flush_in_finalizer1. [ruby-core:43951] [Bug ##6228] diff --git a/test/ruby/test_io.rb b/test/ruby/test_io.rb index ebf9b760dd..be5a3331f0 100644 --- a/test/ruby/test_io.rb +++ b/test/ruby/test_io.rb @@ -1891,7 +1891,7 @@ End } end ensure - fds.each {|fd| IO.for_fd(fd).close rescue next} + GC.start end def test_flush_in_finalizer2