Permalink
Browse files

Use #flush between switching from #write to #syswrite. Closes #4907. …

…[Blair Zajac <blair@orcaware.com>]

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4306 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent f42403f commit c745f4780442271a2a2dcead4567b3fec9057630 Marcel Molina committed Apr 29, 2006
Showing with 5 additions and 0 deletions.
  1. +2 −0 actionpack/CHANGELOG
  2. +3 −0 actionpack/lib/action_controller/cgi_process.rb
View
@@ -1,5 +1,7 @@
*SVN*
+* Use #flush between switching from #write to #syswrite. Closes #4907. [Blair Zajac <blair@orcaware.com>]
+
* Documentation fix: integration test scripts don't require integration_test. Closes #4914. [Frederick Ros <sl33p3r@free.fr>]
* ActionController::Base Summary documentation rewrite. Closes #4900. [kevin.clark@gmail.com]
@@ -180,6 +180,9 @@ def out(output = $stdout)
if @cgi.send(:env_table)['REQUEST_METHOD'] == 'HEAD'
return
elsif @body.respond_to?(:call)
+ # Flush the output now in case the @body Proc uses
+ # #syswrite.
+ output.flush if output.respond_to?(:flush)
@body.call(self, output)
else
output.write(@body)

0 comments on commit c745f47

Please sign in to comment.