mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* ext/socket/socket.c (init_inetsock_internal): remove setting
SO_REUSEADDR option on server socket on Cygwin. fixed: [ruby-core:6765] ([ ruby-Bugs-2872 ]) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9627 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
21d45159de
commit
3be312869d
2 changed files with 8 additions and 3 deletions
|
@ -1,8 +1,8 @@
|
|||
Mon Nov 28 13:20:11 2005 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
Mon Nov 28 18:55:22 2005 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* ext/socket/socket.c (init_inetsock_internal): remove setting
|
||||
SO_REUSEADDR option on server socket. fixed: [ruby-core:6765]
|
||||
([ ruby-Bugs-2872 ])
|
||||
SO_REUSEADDR option on server socket on Cygwin.
|
||||
fixed: [ruby-core:6765] ([ ruby-Bugs-2872 ])
|
||||
|
||||
Mon Nov 28 13:11:45 2005 Hirokazu Yamamoto <ocean@m2.ccsnet.ne.jp>
|
||||
|
||||
|
|
|
@ -1179,6 +1179,11 @@ init_inetsock_internal(arg)
|
|||
}
|
||||
arg->fd = fd;
|
||||
if (type == INET_SERVER) {
|
||||
#if !defined(_WIN32) && !defined(__CYGWIN__)
|
||||
status = 1;
|
||||
setsockopt(fd, SOL_SOCKET, SO_REUSEADDR,
|
||||
(char*)&status, sizeof(status));
|
||||
#endif
|
||||
status = bind(fd, res->ai_addr, res->ai_addrlen);
|
||||
syscall = "bind(2)";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue