зеркало из https://github.com/github/ruby.git
* ext/socket/init.c (rsock_getfamily): return AF_UNSPEC if getsockname
is failed. [ruby-core:24383] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24160 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
ae487eda6e
Коммит
c7550e2a3d
|
@ -1,3 +1,8 @@
|
|||
Fri Jul 17 13:35:47 2009 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* ext/socket/init.c (rsock_getfamily): return AF_UNSPEC if getsockname
|
||||
is failed. [ruby-core:24383]
|
||||
|
||||
Fri Jul 17 01:22:57 2009 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* array.c (recursive_join): raise ArgumentError for joining
|
||||
|
|
|
@ -532,7 +532,7 @@ rsock_getfamily(int sockfd)
|
|||
|
||||
ss.ss_family = AF_UNSPEC;
|
||||
if (getsockname(sockfd, (struct sockaddr*)&ss, &sslen) < 0)
|
||||
rb_sys_fail("getsockname(2)");
|
||||
return AF_UNSPEC;
|
||||
|
||||
return ss.ss_family;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче