Commit cf8eae4f authored by jan.koester's avatar jan.koester
Browse files

TEST

parent 02aa0c1f
Loading
Loading
Loading
Loading
+1 −0
Changes for .gitignore: 1 added line, 0 removed lines.
Original line number Diff line number Diff line
@@ -7,6 +7,7 @@ build/
build-warn/
build-release/
obj-*-linux-gnu/*
obj-x86_64-linux-gnu/*
out/
debian/tmp/*
.kdev4/
+654 −0

File changed.

Preview size limit exceeded, changes collapsed.

+57 −402

File changed.

Preview size limit exceeded, changes collapsed.

+10 −1
Changes for src/http.h: 10 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -161,7 +161,6 @@ namespace libhttppp {
      // _recvTimeoutSec, translating its NetException into HTTPException.
      void _connectTcp(netplus::tcp &sock);
      bool tryHttp3First();
      int readchunk(const char *data,int datasize,int &pos);

      // Non-blocking I/O helpers using poll() for efficient waiting
      size_t _recvBlocking(netplus::buffer &b, int timeout_sec = 0);
@@ -173,8 +172,18 @@ namespace libhttppp {
      // Shared HTTP/1.x response reader (avoids code duplication)
      std::vector<char> _h1ReadResponse(const std::string &label);

      // Shared Get/Post/Put/Delete implementation: builds+sends the request
      // over whichever transport is active (H1/H2/H3), follows redirects
      // per RFC 7231 §6.4 (303 always converts to a bodyless GET; 307/308
      // preserve the original method) when followRedirects is set, and
      // retries up to maxTries times on transport errors.
      const std::vector<char> _doH1Request(const std::string &method, int requestType,
                                            HttpRequest &nreq, const std::vector<char> *body,
                                            size_t maxTries, bool followRedirects);

      // HTTP/2 client helpers
      bool _isH2 = false;
      bool _isH3 = false;                // cached in place of repeated dynamic_cast<quic*>
      bool _h2PrefaceSent = false;       // true after connection preface sent

      // HTTP/3 client helpers