diff options
author | Russ Smith <russ@bashme.org> | 2009-03-11 12:50:24 -0500 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2009-03-11 12:50:24 -0500 |
commit | f2c7508befb085ffe19ec7fb9ca2e6919cc919c9 (patch) | |
tree | 838b029ea24d6d9320082a5b0045d915c10ba1a6 /actionpack/lib/action_controller/vendor/rack-1.0/rack/deflater.rb | |
parent | 106976df0911e423042ec4abc165fd561766a047 (diff) | |
download | rails-f2c7508befb085ffe19ec7fb9ca2e6919cc919c9.tar.gz rails-f2c7508befb085ffe19ec7fb9ca2e6919cc919c9.tar.bz2 rails-f2c7508befb085ffe19ec7fb9ca2e6919cc919c9.zip |
Update bundled Rack to fix Litespeed compatibility [#2198 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
Diffstat (limited to 'actionpack/lib/action_controller/vendor/rack-1.0/rack/deflater.rb')
-rw-r--r-- | actionpack/lib/action_controller/vendor/rack-1.0/rack/deflater.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/vendor/rack-1.0/rack/deflater.rb b/actionpack/lib/action_controller/vendor/rack-1.0/rack/deflater.rb index 3e66680092..a42b7477ae 100644 --- a/actionpack/lib/action_controller/vendor/rack-1.0/rack/deflater.rb +++ b/actionpack/lib/action_controller/vendor/rack-1.0/rack/deflater.rb @@ -36,12 +36,12 @@ module Rack mtime = headers.key?("Last-Modified") ? Time.httpdate(headers["Last-Modified"]) : Time.now body = self.class.gzip(body, mtime) - size = body.respond_to?(:bytesize) ? body.bytesize : body.size + size = Rack::Utils.bytesize(body) headers = headers.merge("Content-Encoding" => "gzip", "Content-Length" => size.to_s) [status, headers, [body]] when "deflate" body = self.class.deflate(body) - size = body.respond_to?(:bytesize) ? body.bytesize : body.size + size = Rack::Utils.bytesize(body) headers = headers.merge("Content-Encoding" => "deflate", "Content-Length" => size.to_s) [status, headers, [body]] when "identity" |