LLM inference in C/C++
C++ ggml
vendor : update cpp-httplib to 0.60.1 (#30134)
Adrien Gallouët03aa006acb54
diff --git a/scripts/sync_vendor.py b/scripts/sync_vendor.pyindex c667fcb0a7..df1ea1eaf1 100755--- a/scripts/sync_vendor.py+++ b/scripts/sync_vendor.py@@ -5,7 +5,7 @@ import osimport sysimport subprocess-HTTPLIB_VERSION = "refs/tags/v0.60.0"+HTTPLIB_VERSION = "refs/tags/v0.60.1"# used by examples/gguf-hash, these repos have no release tag, so we pin a commitXXHASH_COMMIT = "9f465f1ea932d6ad9a26cd77496311ffa544cd68"diff --git a/vendor/cpp-httplib/httplib.cpp b/vendor/cpp-httplib/httplib.cppindex ac6f6cda74..2898454d98 100644--- a/vendor/cpp-httplib/httplib.cpp+++ b/vendor/cpp-httplib/httplib.cpp@@ -5192,8 +5192,10 @@ bool range_error(Request &req, Response &res) {last_pos = content_len;}+ // RFC 9110 14.1.2: a suffix-length longer than the representation+ // selects the entire representation.if (first_pos == -1) {- first_pos = content_len - last_pos;+ first_pos = (std::max)(static_cast<ssize_t>(0), content_len - last_pos);last_pos = content_len - 1;}@@ -6136,12 +6138,6 @@ bool verify_cert_with_windows_schannel(auto chain_guard =scope_exit([&] { CertFreeCertificateChain(chain_context); });- // Check if chain has errors- if (chain_context->TrustStatus.dwErrorStatus != CERT_TRUST_NO_ERROR) {- out_error = chain_context->TrustStatus.dwErrorStatus;- return false;- }-// Verify SSL policySSL_EXTRA_CERT_CHAIN_POLICY_PARA extra_policy_para = {};extra_policy_para.cbSize = sizeof(extra_policy_para);diff --git a/vendor/cpp-httplib/httplib.h b/vendor/cpp-httplib/httplib.hindex 553924015d..95432d01eb 100644--- a/vendor/cpp-httplib/httplib.h+++ b/vendor/cpp-httplib/httplib.h@@ -8,8 +8,8 @@#ifndef CPPHTTPLIB_HTTPLIB_H#define CPPHTTPLIB_HTTPLIB_H-#define CPPHTTPLIB_VERSION "0.60.0"-#define CPPHTTPLIB_VERSION_NUM "0x003c00"+#define CPPHTTPLIB_VERSION "0.60.1"+#define CPPHTTPLIB_VERSION_NUM "0x003c01"#ifdef _WIN32#if defined(_WIN32_WINNT) && _WIN32_WINNT < 0x0A00@@ -4412,6 +4412,8 @@ private:namespace ws {+class WebSocketClient;+enum class Opcode : uint8_t {Continuation = 0x0,Text = 0x1,@@ -4513,7 +4515,7 @@ public:private:friend class httplib::Server;- friend class WebSocketClient;+ friend class httplib::ws::WebSocketClient;WebSocket(Stream &strm, const Request &req, bool is_server,