зеркало из https://github.com/github/ruby.git
* ext/socket/init.c (rsock_connect): add to care EINTR. based
on a patch from Eric Wong at [ruby-core:35621][Bug #4555] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31405 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
4d88169267
Коммит
49b4510cd1
|
@ -1,3 +1,8 @@
|
||||||
|
Mon May 2 00:36:12 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
|
||||||
|
|
||||||
|
* ext/socket/init.c (rsock_connect): add to care EINTR. based
|
||||||
|
on a patch from Eric Wong at [ruby-core:35621][Bug #4555]
|
||||||
|
|
||||||
Sun May 1 01:06:24 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
|
Sun May 1 01:06:24 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
|
||||||
|
|
||||||
* thread.c (rb_thread_select): release GVL while waiting select().
|
* thread.c (rb_thread_select): release GVL while waiting select().
|
||||||
|
|
|
@ -383,6 +383,12 @@ rsock_connect(int fd, const struct sockaddr *sockaddr, int len, int socks)
|
||||||
status = (int)BLOCKING_REGION_FD(func, &arg);
|
status = (int)BLOCKING_REGION_FD(func, &arg);
|
||||||
if (status < 0) {
|
if (status < 0) {
|
||||||
switch (errno) {
|
switch (errno) {
|
||||||
|
case EINTR:
|
||||||
|
#if defined(ERESTART)
|
||||||
|
case ERESTART:
|
||||||
|
#endif
|
||||||
|
continue;
|
||||||
|
|
||||||
case EAGAIN:
|
case EAGAIN:
|
||||||
#ifdef EINPROGRESS
|
#ifdef EINPROGRESS
|
||||||
case EINPROGRESS:
|
case EINPROGRESS:
|
||||||
|
|
Загрузка…
Ссылка в новой задаче