mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/net/smtp.rb (Net::SMTP#data): enable buffering while
'data' send for optimizing Net::SMTP#send_message. [ruby-dev:48329] [misc #9981] patch by Masahiro Tomita. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46793 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f11c30e801
commit
00eb720394
2 changed files with 18 additions and 4 deletions
|
@ -1,3 +1,10 @@
|
|||
Sat Jul 12 04:17:40 2014 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
|
||||
|
||||
* lib/net/smtp.rb (Net::SMTP#data): enable buffering while
|
||||
'data' send for optimizing Net::SMTP#send_message.
|
||||
[ruby-dev:48329] [misc #9981]
|
||||
patch by Masahiro Tomita.
|
||||
|
||||
Sat Jul 12 01:13:45 2014 Naohisa Goto <ngotogenome@gmail.com>
|
||||
|
||||
* test/ruby/envutil.rb (assert_no_memory_leak): On Solaris 9 or later,
|
||||
|
|
|
@ -901,11 +901,18 @@ module Net
|
|||
end
|
||||
res = critical {
|
||||
check_continue get_response('DATA')
|
||||
socket_sync_bak = @socket.io.sync
|
||||
begin
|
||||
@socket.io.sync = false
|
||||
if msgstr
|
||||
@socket.write_message msgstr
|
||||
else
|
||||
@socket.write_message_by_block(&block)
|
||||
end
|
||||
ensure
|
||||
@socket.io.flush
|
||||
@socket.io.sync = socket_sync_bak
|
||||
end
|
||||
recv_response()
|
||||
}
|
||||
check_response res
|
||||
|
|
Loading…
Reference in a new issue