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

ruby-changes:29679

From: akr <ko1@a...>
Date: Tue, 2 Jul 2013 00:43:34 +0900 (JST)
Subject: [ruby-changes:29679] akr:r41731 (trunk): * ext/socket/ipsocket.c (init_inetsock_internal): Don't try mismached

akr	2013-07-02 00:43:21 +0900 (Tue, 02 Jul 2013)

  New Revision: 41731

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

  Log:
    * ext/socket/ipsocket.c (init_inetsock_internal): Don't try mismached
      address family if already failed.

  Modified files:
    trunk/ChangeLog
    trunk/ext/socket/ipsocket.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 41730)
+++ ChangeLog	(revision 41731)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Tue Jul  2 00:39:59 2013  Tanaka Akira  <akr@f...>
+
+	* ext/socket/ipsocket.c (init_inetsock_internal): Don't try mismached
+	  address family if already failed.
+
 Mon Jul  1 23:07:38 2013  NARUSE, Yui  <naruse@r...>
 
 	* template/encdb.h.tmpl: define encoding index macros to use the index
Index: ext/socket/ipsocket.c
===================================================================
--- ext/socket/ipsocket.c	(revision 41730)
+++ ext/socket/ipsocket.c	(revision 41731)
@@ -69,7 +69,7 @@ init_inetsock_internal(struct inetsock_a https://github.com/ruby/ruby/blob/trunk/ext/socket/ipsocket.c#L69
                     break;
             }
             if (!lres) {
-                if (res->ai_next)
+                if (res->ai_next || status < 0)
                     continue;
                 /* Use a different family local address if no choice, this
                  * will cause EAFNOSUPPORT. */

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

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