* ext/socket/ipsocket.c (init_inetsock_internal): Use an address
family for local address wihch is different to the remote address if no other choice. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41724 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f6a8c82e2d
commit
b7fd00c8fa
@ -1,3 +1,9 @@
|
|||||||
|
Mon Jul 1 20:03:39 2013 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
|
* ext/socket/ipsocket.c (init_inetsock_internal): Use an address
|
||||||
|
family for local address wihch is different to the remote
|
||||||
|
address if no other choice.
|
||||||
|
|
||||||
Mon Jul 1 15:05:00 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Mon Jul 1 15:05:00 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* lib/csv.rb (CSV#<<): use StringIO#set_encoding instead of creating
|
* lib/csv.rb (CSV#<<): use StringIO#set_encoding instead of creating
|
||||||
|
@ -68,8 +68,13 @@ init_inetsock_internal(struct inetsock_arg *arg)
|
|||||||
if (lres->ai_family == res->ai_family)
|
if (lres->ai_family == res->ai_family)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (!lres)
|
if (!lres) {
|
||||||
continue;
|
if (res->ai_next)
|
||||||
|
continue;
|
||||||
|
/* Use a different family local address if no choice, this
|
||||||
|
* will cause EAFNOSUPPORT. */
|
||||||
|
lres = arg->local.res;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
status = rsock_socket(res->ai_family,res->ai_socktype,res->ai_protocol);
|
status = rsock_socket(res->ai_family,res->ai_socktype,res->ai_protocol);
|
||||||
syscall = "socket(2)";
|
syscall = "socket(2)";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user