From c9a4eee58eb36a3634748cc838304334e641e2de Mon Sep 17 00:00:00 2001
From: iProgramInCpp <iprogramincpp@gmail.com>
Date: Sat, 8 Jun 2024 20:05:55 +0300
Subject: [PATCH] * Increase recv buffer size to try to thwart "SSL connection
 failed" errors.

---
 deps/httplib/httplib.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/deps/httplib/httplib.h b/deps/httplib/httplib.h
index 2f3f9e3..41f1d42 100644
--- a/deps/httplib/httplib.h
+++ b/deps/httplib/httplib.h
@@ -94,11 +94,11 @@ extern int g_latestSSLError; // HACK - To debug an "SSL connection failed" issue
 #endif
 
 #ifndef CPPHTTPLIB_RECV_BUFSIZ
-#define CPPHTTPLIB_RECV_BUFSIZ size_t(4096u)
+#define CPPHTTPLIB_RECV_BUFSIZ size_t(16384u)
 #endif
 
 #ifndef CPPHTTPLIB_COMPRESSION_BUFSIZ
-#define CPPHTTPLIB_COMPRESSION_BUFSIZ size_t(16384u)
+#define CPPHTTPLIB_COMPRESSION_BUFSIZ size_t(32768u)
 #endif
 
 #ifndef CPPHTTPLIB_THREAD_POOL_COUNT
@@ -2465,7 +2465,7 @@ inline ssize_t select_read(socket_t sock, time_t sec, time_t usec) {
   if (sock >= FD_SETSIZE) { return 1; }
 #endif
 
-  fd_set fds;
+  fd_set fds{};
   FD_ZERO(&fds);
   FD_SET(sock, &fds);
 
@@ -2493,7 +2493,7 @@ inline ssize_t select_write(socket_t sock, time_t sec, time_t usec) {
   if (sock >= FD_SETSIZE) { return 1; }
 #endif
 
-  fd_set fds;
+  fd_set fds{};
   FD_ZERO(&fds);
   FD_SET(sock, &fds);