Commit 8630249f authored by Shinya Maeda's avatar Shinya Maeda

Support IO.copy_stream

parent 26fec9d4
......@@ -88,11 +88,11 @@ module Gitlab
@tell += data.bytesize
end
# TODO: If we support `IO::copy_stream`, outbuf must be handled properly
# if outbuf
# outbuf.slice!(/.*/)
# outbuf << out
# end
# If outbuf is passed, we put the output into the buffer. This supports IO.copy_stream functionality
if outbuf
outbuf.slice!(0, outbuf.bytesize)
outbuf << out
end
out
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment