docs: public synchronized Headers takeHeaders() throws IOException {
      readTimeout.enter();
      try {
        while (headersQueue.isEmpty() && errorCode == null) {
          waitForIo();
        }
      } finally {
        readTimeout.exitAndThrowIfTimedOut();
      }
      if (!headersQueue.isEmpty()) {
        return headersQueue.removeFirst();
      }
      throw errorException != null ? errorException : new StreamResetException(errorCode);
    }