code: @Override
  	public void received(ByteBuffer buffer) {
  		if (ended) {
  			throw new IllegalStateException();
  		}
  		
  		if ((countRead + buffer.remaining()) > contentLength) {
  			ByteBuffer b = buffer.duplicate();
  			int l = (int) (contentLength - countRead);
  			b.limit(b.position() + l);
  			buffer.position(buffer.position() + l);
  			buffer = b;
  		}
  		
  		countRead += buffer.remaining();
  		if (buffer.hasRemaining()) {
  			wrappee.received(buffer);
  		}
  		if (countRead == contentLength) {
  			ended = true;
  			wrappee.ended();
  		}
  	}
docs: MUST sync-ly consume buffer