mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/net/protocol.rb: logging response body. [experimental] [ruby-list:38800]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4966 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
fb12e23803
commit
5af1243076
2 changed files with 9 additions and 4 deletions
|
@ -1,3 +1,8 @@
|
|||
Sun Nov 16 12:16:10 2003 Minero Aoki <aamine@loveruby.net>
|
||||
|
||||
* lib/net/protocol.rb: logging response body. [experimental]
|
||||
[ruby-list:38800]
|
||||
|
||||
Sun Nov 16 10:49:38 2003 Gavin Sinclair <gsinclair@soyabean.com.au>
|
||||
|
||||
* lib/thread.rb (Thread.exclusive): wrap method definition in
|
||||
|
|
|
@ -120,7 +120,7 @@ module Net # :nodoc:
|
|||
|
||||
def read( len, dest = '', ignore_eof = false )
|
||||
LOG "reading #{len} bytes..."
|
||||
LOG_off()
|
||||
# LOG_off() # experimental: [ruby-list:38800]
|
||||
read_bytes = 0
|
||||
begin
|
||||
while read_bytes + @rbuf.size < len
|
||||
|
@ -131,14 +131,14 @@ module Net # :nodoc:
|
|||
rescue EOFError
|
||||
raise unless ignore_eof
|
||||
end
|
||||
LOG_on()
|
||||
# LOG_on()
|
||||
LOG "read #{read_bytes} bytes"
|
||||
dest
|
||||
end
|
||||
|
||||
def read_all( dest = '' )
|
||||
LOG 'reading all...'
|
||||
LOG_off()
|
||||
# LOG_off() # experimental: [ruby-list:38800]
|
||||
read_bytes = 0
|
||||
begin
|
||||
while true
|
||||
|
@ -148,7 +148,7 @@ module Net # :nodoc:
|
|||
rescue EOFError
|
||||
;
|
||||
end
|
||||
LOG_on()
|
||||
# LOG_on()
|
||||
LOG "read #{read_bytes} bytes"
|
||||
dest
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue