ruby-changes:33450
From: naruse <ko1@a...>
Date: Mon, 7 Apr 2014 07:27:39 +0900 (JST)
Subject: [ruby-changes:33450] naruse:r45529 (trunk): * lib/xmlrpc/client.rb (do_rpc): don't check body length.
naruse 2014-04-07 07:26:55 +0900 (Mon, 07 Apr 2014) New Revision: 45529 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=45529 Log: * lib/xmlrpc/client.rb (do_rpc): don't check body length. If HTTP content-encoding is used, the length may be different. [Bug #8182] [ruby-core:53811] Modified files: trunk/ChangeLog trunk/lib/xmlrpc/client.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 45528) +++ ChangeLog (revision 45529) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Mon Apr 7 07:20:23 2014 NARUSE, Yui <naruse@r...> + + * lib/xmlrpc/client.rb (do_rpc): don't check body length. + If HTTP content-encoding is used, the length may be different. + [Bug #8182] [ruby-core:53811] + Mon Apr 7 02:39:48 2014 Marc-Andre Lafortune <ruby-core@m...> * lib/matrix.rb: Add Matrix#cofactor [fix GH-568] Index: lib/xmlrpc/client.rb =================================================================== --- lib/xmlrpc/client.rb (revision 45528) +++ lib/xmlrpc/client.rb (revision 45529) @@ -507,8 +507,6 @@ module XMLRPC # :nodoc: https://github.com/ruby/ruby/blob/trunk/lib/xmlrpc/client.rb#L507 expected = resp["Content-Length"] || "<unknown>" if data.nil? or data.bytesize == 0 raise "Wrong size. Was #{data.bytesize}, should be #{expected}" - elsif expected != "<unknown>" and expected.to_i != data.bytesize and resp["Transfer-Encoding"].nil? - raise "Wrong size. Was #{data.bytesize}, should be #{expected}" end parse_set_cookies(resp.get_fields("Set-Cookie")) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/