Commit 4a55a5c4 authored by Jan Koester's avatar Jan Koester
Browse files

test

parent e1d0a26f
Loading
Loading
Loading
Loading
+12 −4
Changes for src/http.cpp: 12 added lines, 4 removed lines.
Original line number Diff line number Diff line
@@ -919,7 +919,9 @@ libhttppp::HttpResponse libhttppp::HttpClient::GetStream(libhttppp::HttpRequest

        // ── HTTP/3 (QUIC) streaming path ──
        if (auto *q = dynamic_cast<netplus::quic*>(_cltsock.get())) {
            std::string path = nreq.getRequestURL();
            // :path must carry the query string too (e.g. Git smart HTTP ?service=git-upload-pack);
            // getRequestURL() strips it, getRequest() is the full target.
            std::string path = nreq.getRequestURL().empty() ? std::string() : nreq.getRequest();
            if (path.empty()) path = _url.getPath();
            std::string scheme = (_url.getProtocol() == HttpUrl::HTTP) ? "http" : "https";
            std::string authority = _url.getHost() + ":" + std::to_string(_url.getPort());
@@ -1089,7 +1091,9 @@ libhttppp::HttpResponse libhttppp::HttpClient::GetStream(libhttppp::HttpRequest
                _h2PrefaceSent = true;
            }

            std::string path = nreq.getRequestURL();
            // :path must carry the query string too (e.g. Git smart HTTP ?service=git-upload-pack);
            // getRequestURL() strips it, getRequest() is the full target.
            std::string path = nreq.getRequestURL().empty() ? std::string() : nreq.getRequest();
            if (path.empty()) path = _url.getPath();
            std::string scheme = (_url.getProtocol() == HttpUrl::HTTPS) ? "https" : "http";
            std::string auth = _url.getHost() + ":" + std::to_string(_url.getPort());
@@ -2563,7 +2567,9 @@ const std::vector<char> libhttppp::HttpClient::_h2Request(
        }

        // 2) Build HEADERS frame for stream 1
        std::string path = nreq.getRequestURL();
        // :path must carry the query string too (e.g. Git smart HTTP ?service=git-upload-pack);
        // getRequestURL() strips it, getRequest() is the full target.
        std::string path = nreq.getRequestURL().empty() ? std::string() : nreq.getRequest();
        if (path.empty()) path = _url.getPath();

        std::string scheme = (_url.getProtocol() == HttpUrl::HTTPS) ? "https" : "http";
@@ -3010,7 +3016,9 @@ const std::vector<char> libhttppp::HttpClient::_h2Request(
      throw ee;
    }

    std::string path = nreq.getRequestURL();
    // :path must carry the query string too (e.g. Git smart HTTP ?service=git-upload-pack);
    // getRequestURL() strips it, getRequest() is the full target.
    std::string path = nreq.getRequestURL().empty() ? std::string() : nreq.getRequest();
      if (path.empty()) path = _url.getPath();

      std::string scheme = (_url.getProtocol() == HttpUrl::HTTP) ? "http" : "https";