class Async::HTTP::Body::Pipe

def reader(task)

Read from the @input stream and write to the head of the pipe.
def reader(task)
	@reader = task
	
	task.annotate "pipe reader"
	
	while chunk = @input.read
		@head.write(chunk)
		@head.flush
	end
	
	@head.close_write
ensure
	@reader = nil
	@input.close($!)
	
	@head.close if @writer.nil?
end