Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed access to "Host" header with requests made by crappy old HTTP/1…

….0 clients #2124 [Marcel Molina]

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2242 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
commit 7c042e09b43fa64492a54350aad691f6763809d8 1 parent 5e3364e
@dhh dhh authored
View
2  actionpack/CHANGELOG
@@ -1,5 +1,7 @@
*SVN*
+* Fixed access to "Host" header with requests made by crappy old HTTP/1.0 clients #2124 [Marcel Molina]
+
* Added easy assignment of fragment cache store through use of symbols for included stores (old way still works too)
Before:
View
2  actionpack/lib/action_controller/cgi_process.rb
@@ -79,7 +79,7 @@ def cookies
end
def host
- env["HTTP_X_FORWARDED_HOST"] || @cgi.host.to_s.split(":").first
+ env["HTTP_X_FORWARDED_HOST"] || @cgi.host.to_s.split(":").first || ''
end
def session
Please sign in to comment.
Something went wrong with that request. Please try again.