ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
* [ruby-core:45062] [ruby-trunk - Bug #6436][Open] Byte counting incorrect in BufferedIO (net/protocol.rb)
@ 2012-05-15 20:10 jcast (Jeremie Castagna)
  2012-05-15 20:27 ` [ruby-core:45063] [ruby-trunk - Bug #6436] " jcast (Jeremie Castagna)
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: jcast (Jeremie Castagna) @ 2012-05-15 20:10 UTC (permalink / raw)
  To: ruby-core


Issue #6436 has been reported by jcast (Jeremie Castagna).

----------------------------------------
Bug #6436: Byte counting incorrect in BufferedIO (net/protocol.rb)
https://bugs.ruby-lang.org/issues/6436

Author: jcast (Jeremie Castagna)
Status: Open
Priority: Normal
Assignee: 
Category: 
Target version: 
ruby -v: 1.9


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


-- 
http://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-08-15  1:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-05-15 20:10 [ruby-core:45062] [ruby-trunk - Bug #6436][Open] Byte counting incorrect in BufferedIO (net/protocol.rb) jcast (Jeremie Castagna)
2012-05-15 20:27 ` [ruby-core:45063] [ruby-trunk - Bug #6436] " jcast (Jeremie Castagna)
2012-05-15 23:52   ` [ruby-core:45068] " Eric Wong
2012-05-16  1:05 ` [ruby-core:45070] " nobu (Nobuyoshi Nakada)
2012-05-16 16:03 ` [ruby-core:45094] [ruby-trunk - Bug #6436][Assigned] " mame (Yusuke Endoh)
2019-08-15  1:41 ` [ruby-core:94361] [Ruby master Bug#6436] " merch-redmine

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).