From: Koichi Sasada Date: 2011-06-11T15:43:25+09:00 Subject: [ruby-core:36988] [Ruby 1.9 - Bug #4318][Feedback] Legacy bug in net/imap in Ruby 1.9.x Issue #4318 has been updated by Koichi Sasada. Status changed from Assigned to Feedback ---------------------------------------- Bug #4318: Legacy bug in net/imap in Ruby 1.9.x http://redmine.ruby-lang.org/issues/4318 Author: T. N. T. Status: Feedback Priority: Normal Assignee: Shugo Maeda Category: lib Target version: 1.9.x ruby -v: ruby 1.9.2p0 (2010-08-18 revision 29036) [i686-linux] (but it is also in the current patchlevel136) =begin Emails that get 'appended' to a mailbox are cut-off at the end. Not always but only in non-multipart mails where the headers Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit apply to the whole content. This fixes the problem: module Net class IMAP def send_literal(str) put_string("{" + str.bytesize.to_s + "}" + CRLF) @continuation_request_arrival.wait raise @exception if @exception put_string(str) end end end The change is "str.length.to_s" -> "str.bytesize.to_s". Regards, T. =end -- http://redmine.ruby-lang.org