class Async::HTTP::Protocol::HTTP11::ChunkedBody

def each

def each
	return if @closed
	
	while true
		size = @protocol.read_line.to_i(16)
		
		if size == 0
			@protocol.read_line
			
			@closed = true
			
			return
		end
		
		chunk = @protocol.stream.read(size)
		@protocol.read_line # Consume the trailing CRLF
		
		yield chunk
	end
end