diff options
author | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-05-31 00:11:17 +0000 |
---|---|---|
committer | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-05-31 00:11:17 +0000 |
commit | d3818d6b55af209f9e75a3dda098510a525fcd71 (patch) | |
tree | f7fd5c3ee519b4399f3b3ffedd052514b862bc57 /ext | |
parent | 766c32adc3c2d6848fea2e7d7976bdb9f26487b9 (diff) |
merges r31405 from trunk into ruby_1_9_2.
--
* 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/branches/ruby_1_9_2@31829 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
-rw-r--r-- | ext/socket/init.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ext/socket/init.c b/ext/socket/init.c index ffd1c72895..48718313f0 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(func, &arg); if (status < 0) { switch (errno) { + case EINTR: +#if defined(ERESTART) + case ERESTART: +#endif + continue; + case EAGAIN: #ifdef EINPROGRESS case EINPROGRESS: |