Actions
Bug #6436
closedByte counting incorrect in BufferedIO (net/protocol.rb)
Bug #6436:
Byte counting incorrect in BufferedIO (net/protocol.rb)
Description
BufferedIO's @rbuf counts bytes with String#size, but should use String#bytesize. This creates potential incorrect reading of a HTTP body when changing the encoding of each chuck passed by HTTP#read_body:
http.read_body do |chunk|
chunk.force_encoding "UTF-8"
end
Files
Actions