diff options
author | Eric Wong <normalperson@yhbt.net> | 2010-12-30 08:32:24 +0000 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2011-01-04 16:21:17 -0800 |
commit | 72a315441937f9e0531112f2b7080da39ca6064d (patch) | |
tree | fe310ac81f73605f2e278d8680aaf9eb4e755a71 /lib/rainbows/coolio/thread_client.rb | |
parent | 1f28534fce2b30bf3099ea0d014b62ac4a3205f0 (diff) | |
download | rainbows-72a315441937f9e0531112f2b7080da39ca6064d.tar.gz |
This lets us simplify repetitive checks worry less about properly maintaining/closing client connections for each concurrency model we support.
Diffstat (limited to 'lib/rainbows/coolio/thread_client.rb')
-rw-r--r-- | lib/rainbows/coolio/thread_client.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/rainbows/coolio/thread_client.rb b/lib/rainbows/coolio/thread_client.rb index 3ada7bf..e6db2bd 100644 --- a/lib/rainbows/coolio/thread_client.rb +++ b/lib/rainbows/coolio/thread_client.rb @@ -14,10 +14,8 @@ class Rainbows::Coolio::ThreadClient < Rainbows::Coolio::Client # this is only called in the master thread def response_write(response) - alive = @hp.next? && G.alive - coolio_write_response(response, alive) + coolio_write_response(response, alive = @hp.next?) return quit unless alive && :close != @state - @state = :headers rescue => e handle_error(e) |