aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-06-29 10:04:33 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-06-29 10:04:33 +0000
commit26b1e8622d7a08f90a7a5d2aecdcee9d1aa57224 (patch)
treeec4b84b39a965fac0925a15fac0c0b2afa4ef9e6 /lib
parente8c97b99dc8b69a582becb1c8a7a0fba6796645c (diff)
downloadruby-26b1e8622d7a08f90a7a5d2aecdcee9d1aa57224.tar.gz
fix previous commit for nil case
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib')
-rw-r--r--lib/net/http/response.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/net/http/response.rb b/lib/net/http/response.rb
index 219e14e777..674faf2cfc 100644
--- a/lib/net/http/response.rb
+++ b/lib/net/http/response.rb
@@ -250,7 +250,8 @@ class Net::HTTPResponse
return yield @socket unless @decode_content
return yield @socket if self['content-range']
- case self['content-encoding'].downcase
+ v = self['content-encoding']
+ case v && v.downcase
when 'deflate', 'gzip', 'x-gzip' then
self.delete 'content-encoding'