Skip to content

Commit 6bc97ee

Browse files
committed
merge revision(s) 30457:
* ext/socket/socket.c (make_addrinfo): skip IPv6 addresses when ruby doesn't support IPv6 but system supports it. [ruby-dev:42944] (ruby#4230) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@30457 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Signed-off-by: URABE, Shyouhei <shyouhei@ruby-lang.org> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_7@31660 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
1 parent 9c2fba7 commit 6bc97ee

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

ChangeLog

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
Fri May 20 23:23:45 2011 NAKAMURA Usaku <usa@ruby-lang.org>
2+
3+
* ext/socket/socket.c (make_addrinfo): skip IPv6 addresses when ruby
4+
doesn't support IPv6 but system supports it.
5+
[ruby-dev:42944] (#4230)
6+
17
Fri May 20 23:10:07 2011 NAKAMURA Usaku <usa@ruby-lang.org>
28

39
* win32/README.win32: note to need NT based OS to build ruby.

ext/socket/socket.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3218,6 +3218,10 @@ make_addrinfo(res0)
32183218
}
32193219
base = rb_ary_new();
32203220
for (res = res0; res; res = res->ai_next) {
3221+
#if defined(AF_INET6) && !defined(INET6) /* workaround for Windows */
3222+
if (res->ai_addr->sa_family == AF_INET6)
3223+
continue;
3224+
#endif
32213225
ary = ipaddr(res->ai_addr);
32223226
rb_ary_push(ary, INT2FIX(res->ai_family));
32233227
rb_ary_push(ary, INT2FIX(res->ai_socktype));

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy