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

ruby-changes:17518

From: naruse <ko1@a...>
Date: Mon, 18 Oct 2010 10:20:47 +0900 (JST)
Subject: [ruby-changes:17518] Ruby:r29523 (trunk): * lib/net/http.rb (transport_request): @socket may be nil.

naruse	2010-10-18 10:20:37 +0900 (Mon, 18 Oct 2010)

  New Revision: 29523

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

  Log:
    * lib/net/http.rb (transport_request): @socket may be nil.
      patched by Egbert Eich [ruby-core:32829]

  Modified files:
    trunk/ChangeLog
    trunk/lib/net/http.rb

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 29522)
+++ ChangeLog	(revision 29523)
@@ -1,3 +1,8 @@
+Mon Oct 18 10:19:00 2010  NARUSE, Yui  <naruse@r...>
+
+	* lib/net/http.rb (transport_request): @socket may be nil.
+	  patched by Egbert Eich [ruby-core:32829]
+
 Mon Oct 18 09:57:28 2010  NARUSE, Yui  <naruse@r...>
 
 	* sprintf.c (BSD_vfprintf): wrong padding arround prefix and
Index: lib/net/http.rb
===================================================================
--- lib/net/http.rb	(revision 29522)
+++ lib/net/http.rb	(revision 29523)
@@ -1201,7 +1201,7 @@
       res
     rescue => exception
       D "Conn close because of error #{exception}"
-      @socket.close unless @socket.closed?
+      @socket.close if @socket and not @socket.closed?
       raise exception
     end
 

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

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