diff --git a/ChangeLog b/ChangeLog index 7437ffe63a..e40b890a41 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Mon May 2 00:36:12 2011 KOSAKI Motohiro + + * 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 * thread.c (rb_thread_select): release GVL while waiting select(). diff --git a/ext/socket/init.c b/ext/socket/init.c index 137027a531..ee88e81bae 100644 --- a/ext/socket/init.c +++ b/ext/socket/init.c @@ -383,6 +383,12 @@ rsock_connect(int fd, const struct sockaddr *sockaddr, int len, int socks) status = (int)BLOCKING_REGION_FD(func, &arg); if (status < 0) { switch (errno) { + case EINTR: +#if defined(ERESTART) + case ERESTART: +#endif + continue; + case EAGAIN: #ifdef EINPROGRESS case EINPROGRESS: