diff options
author | aamine <aamine@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-06-12 15:45:58 +0000 |
---|---|---|
committer | aamine <aamine@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-06-12 15:45:58 +0000 |
commit | 06e0ba2fe3d95384a5ddab59707c8225f80bb5ed (patch) | |
tree | 0bc2bddd308696a6519c2616ce60377e43a1e345 | |
parent | d8efc64b06d1551600f8bff159df600966d779ce (diff) | |
download | ruby-06e0ba2fe3d95384a5ddab59707c8225f80bb5ed.tar.gz ruby-06e0ba2fe3d95384a5ddab59707c8225f80bb5ed.tar.xz ruby-06e0ba2fe3d95384a5ddab59707c8225f80bb5ed.zip |
o http.rb: body is in HTTPResponse
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@744 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | lib/net/http.rb | 4 | ||||
-rw-r--r-- | lib/net/protocol.rb | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/lib/net/http.rb b/lib/net/http.rb index 40025d06a..d36423795 100644 --- a/lib/net/http.rb +++ b/lib/net/http.rb @@ -352,9 +352,11 @@ All "key" is case-insensitive. super( code_type, code, msg ) @data = {} @http_body_exist = bexist + @body = nil end attr_reader :http_body_exist + attr_accessor :body def []( key ) @data[ key.downcase ] @@ -523,6 +525,8 @@ All "key" is case-insensitive. end def get_body( resp, dest ) + resp.body = dest + if resp.http_body_exist then if chunked? resp then read_chunked( dest, resp ) diff --git a/lib/net/protocol.rb b/lib/net/protocol.rb index 01b659f72..18d82ddca 100644 --- a/lib/net/protocol.rb +++ b/lib/net/protocol.rb @@ -68,7 +68,7 @@ Object class Protocol - Version = '1.1.21' + Version = '1.1.22' class << self |