[前][次][番号順一覧][スレッド一覧]

ruby-changes:34862

From: nobu <ko1@a...>
Date: Fri, 25 Jul 2014 16:56:06 +0900 (JST)
Subject: [ruby-changes:34862] nobu:r46945 (trunk): rubygems/util.rb: fix leaked FDs

nobu	2014-07-25 16:55:48 +0900 (Fri, 25 Jul 2014)

  New Revision: 46945

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=46945

  Log:
    rubygems/util.rb: fix leaked FDs
    
    * lib/rubygems/util.rb (silent_system): close duplicated IOs.

  Modified files:
    trunk/lib/rubygems/util.rb
Index: lib/rubygems/util.rb
===================================================================
--- lib/rubygems/util.rb	(revision 46944)
+++ lib/rubygems/util.rb	(revision 46945)
@@ -88,6 +88,8 @@ module Gem::Util https://github.com/ruby/ruby/blob/trunk/lib/rubygems/util.rb#L88
       ensure
         STDOUT.reopen stdout
         STDERR.reopen stderr
+        stdout.close
+        stderr.close
       end
     end
   end

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]