diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-07-06 13:59:12 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-07-06 13:59:12 +0000 |
commit | 5bf4c6a635d30ba2e209fa9a2f824e06a6fa479b (patch) | |
tree | e4fc01f9a83c6b5bebf8e44bd50e12d7893400fe /io.c | |
parent | 80b9fb5a7b9b96589d3b096e42af2796b07b560d (diff) | |
download | ruby-5bf4c6a635d30ba2e209fa9a2f824e06a6fa479b.tar.gz |
* io.c (nogvl_copy_stream_sendfile): jump to retry_sendfile directly
to avoid select() on a socket which TCP state is CLOSED.
patch by Eric Wong. [ruby-core:31053]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -8147,8 +8147,7 @@ nogvl_copy_stream_sendfile(struct copy_stream_struct *stp) stp->total += ss; copy_length -= ss; if (0 < copy_length) { - ss = -1; - errno = EAGAIN; + goto retry_sendfile; } } if (ss == -1) { |