diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-06-22 12:59:36 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-06-22 12:59:36 +0000 |
commit | 4e0ffab8b05f5cc35996ac4866ee61cefb432af6 (patch) | |
tree | 897aea07971f463340d944efadefe9d4dc678bfe /actionpack | |
parent | ce44079818c9307ed20a2f11b2bf7933803f78f7 (diff) | |
download | rails-4e0ffab8b05f5cc35996ac4866ee61cefb432af6.tar.gz rails-4e0ffab8b05f5cc35996ac4866ee61cefb432af6.tar.bz2 rails-4e0ffab8b05f5cc35996ac4866ee61cefb432af6.zip |
Removed the mutex from the WEBrick adapter under the production environment so concurrent requests can be served
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1482 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/lib/action_controller/cgi_process.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/actionpack/lib/action_controller/cgi_process.rb b/actionpack/lib/action_controller/cgi_process.rb index 9166a8d433..e4e86615c0 100644 --- a/actionpack/lib/action_controller/cgi_process.rb +++ b/actionpack/lib/action_controller/cgi_process.rb @@ -124,20 +124,20 @@ module ActionController #:nodoc: super() end - def out + def out(output = $stdout) convert_content_type!(@headers) - $stdout.binmode if $stdout.respond_to?(:binmode) - $stdout.sync = false + output.binmode if output.respond_to?(:binmode) + output.sync = false if output.respond_to?(:sync=) begin - print @cgi.header(@headers) + output.write(@cgi.header(@headers)) if @cgi.send(:env_table)['REQUEST_METHOD'] == 'HEAD' return elsif @body.respond_to?(:call) @body.call(self) else - print @body + output.write(@body) end rescue Errno::EPIPE => e # lost connection to the FCGI process -- ignore the output, then |