diff options
author | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-05-31 01:49:45 +0000 |
---|---|---|
committer | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-05-31 01:49:45 +0000 |
commit | d96b56b3135f9f4fbf348a5754549f3f904d4921 (patch) | |
tree | 46b06fdbcb63f91d2aaec3c563750beffc42e6c7 /io.c | |
parent | 031d624b3817d54d06674d8019e0d5f79e1485df (diff) |
merges r28557 from trunk into ruby_1_9_2. Fixes #4506.
--
* 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/branches/ruby_1_9_2@31845 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -8218,8 +8218,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) { |