Skip to content

Commit

Permalink
Update libcurl to 8.11.1 with enabled websockets
Browse files Browse the repository at this point in the history
  • Loading branch information
whyoleg authored and osipxd committed Jan 10, 2025
1 parent b42d338 commit 81eae75
Show file tree
Hide file tree
Showing 13 changed files with 36 additions and 34 deletions.
44 changes: 25 additions & 19 deletions ktor-client/ktor-client-curl/desktop/interop/include/curl/curl.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,15 @@
*/

#ifdef CURL_NO_OLDIES
#define CURL_STRICTER
#define CURL_STRICTER /* not used since 8.11.0 */
#endif

/* Compile-time deprecation macros. */
#if (defined(__GNUC__) && \
((__GNUC__ > 12) || ((__GNUC__ == 12) && (__GNUC_MINOR__ >= 1 ))) || \
defined(__IAR_SYSTEMS_ICC__)) && \
!defined(__INTEL_COMPILER) && \
#if (defined(__GNUC__) && \
((__GNUC__ > 12) || ((__GNUC__ == 12) && (__GNUC_MINOR__ >= 1))) || \
(defined(__clang__) && __clang_major__ >= 3) || \
defined(__IAR_SYSTEMS_ICC__)) && \
!defined(__INTEL_COMPILER) && \
!defined(CURL_DISABLE_DEPRECATION) && !defined(BUILDING_LIBCURL)
#define CURL_DEPRECATED(version, message) \
__attribute__((deprecated("since " # version ". " message)))
Expand Down Expand Up @@ -113,13 +114,8 @@
extern "C" {
#endif

#if defined(BUILDING_LIBCURL) || defined(CURL_STRICTER)
typedef struct Curl_easy CURL;
typedef struct Curl_share CURLSH;
#else
typedef void CURL;
typedef void CURLSH;
#endif

/*
* libcurl external API function linkage decorations.
Expand Down Expand Up @@ -253,12 +249,12 @@ typedef int (*curl_xferinfo_callback)(void *clientp,
#endif

#ifndef CURL_MAX_WRITE_SIZE
/* Tests have proven that 20K is a very bad buffer size for uploads on
Windows, while 16K for some odd reason performed a lot better.
We do the ifndef check to allow this value to easier be changed at build
time for those who feel adventurous. The practical minimum is about
400 bytes since libcurl uses a buffer of this size as a scratch area
(unrelated to network send operations). */
/* Tests have proven that 20K is a bad buffer size for uploads on Windows,
while 16K for some odd reason performed a lot better. We do the ifndef
check to allow this value to easier be changed at build time for those
who feel adventurous. The practical minimum is about 400 bytes since
libcurl uses a buffer of this size as a scratch area (unrelated to
network send operations). */
#define CURL_MAX_WRITE_SIZE 16384
#endif

Expand Down Expand Up @@ -555,14 +551,14 @@ typedef enum {
CURLE_FTP_COULDNT_USE_REST, /* 31 - the REST command failed */
CURLE_OBSOLETE32, /* 32 - NOT USED */
CURLE_RANGE_ERROR, /* 33 - RANGE "command" did not work */
CURLE_HTTP_POST_ERROR, /* 34 */
CURLE_OBSOLETE34, /* 34 */
CURLE_SSL_CONNECT_ERROR, /* 35 - wrong when connecting with SSL */
CURLE_BAD_DOWNLOAD_RESUME, /* 36 - could not resume download */
CURLE_FILE_COULDNT_READ_FILE, /* 37 */
CURLE_LDAP_CANNOT_BIND, /* 38 */
CURLE_LDAP_SEARCH_FAILED, /* 39 */
CURLE_OBSOLETE40, /* 40 - NOT USED */
CURLE_FUNCTION_NOT_FOUND, /* 41 - NOT USED starting with 7.53.0 */
CURLE_OBSOLETE41, /* 41 - NOT USED starting with 7.53.0 */
CURLE_ABORTED_BY_CALLBACK, /* 42 */
CURLE_BAD_FUNCTION_ARGUMENT, /* 43 */
CURLE_OBSOLETE44, /* 44 - NOT USED */
Expand Down Expand Up @@ -647,6 +643,12 @@ typedef enum {
#ifndef CURL_NO_OLDIES /* define this to test if your app builds with all
the obsolete stuff removed! */

/* removed in 7.53.0 */
#define CURLE_FUNCTION_NOT_FOUND CURLE_OBSOLETE41

/* removed in 7.56.0 */
#define CURLE_HTTP_POST_ERROR CURLE_OBSOLETE34

/* Previously obsolete error code reused in 7.38.0 */
#define CURLE_OBSOLETE16 CURLE_HTTP2

Expand Down Expand Up @@ -942,6 +944,9 @@ typedef enum {
a client certificate for authentication. (Schannel) */
#define CURLSSLOPT_AUTO_CLIENT_CERT (1<<5)

/* If possible, send data using TLS 1.3 early data */
#define CURLSSLOPT_EARLYDATA (1<<6)

/* The default connection attempt delay in milliseconds for happy eyeballs.
CURLOPT_HAPPY_EYEBALLS_TIMEOUT_MS.3 and happy-eyeballs-timeout-ms.d document
this value, keep them in sync. */
Expand Down Expand Up @@ -2953,7 +2958,8 @@ typedef enum {
CURLINFO_QUEUE_TIME_T = CURLINFO_OFF_T + 65,
CURLINFO_USED_PROXY = CURLINFO_LONG + 66,
CURLINFO_POSTTRANSFER_TIME_T = CURLINFO_OFF_T + 67,
CURLINFO_LASTONE = 67
CURLINFO_EARLYDATA_SENT_T = CURLINFO_OFF_T + 68,
CURLINFO_LASTONE = 68
} CURLINFO;

/* CURLINFO_RESPONSE_CODE is the new name for the option previously known as
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@

/* This is the version number of the libcurl package from which this header
file origins: */
#define LIBCURL_VERSION "8.10.1"
#define LIBCURL_VERSION "8.11.1"

/* The numeric version number is also available "in parts" by using these
defines: */
#define LIBCURL_VERSION_MAJOR 8
#define LIBCURL_VERSION_MINOR 10
#define LIBCURL_VERSION_MINOR 11
#define LIBCURL_VERSION_PATCH 1

/* This is the numeric version of the libcurl version number, meant for easier
Expand All @@ -59,7 +59,7 @@
CURL_VERSION_BITS() macro since curl's own configure script greps for it
and needs it to contain the full number.
*/
#define LIBCURL_VERSION_NUM 0x080a01
#define LIBCURL_VERSION_NUM 0x080b01

/*
* This is the date and time when the full source package was created. The
Expand All @@ -70,7 +70,7 @@
*
* "2007-11-23"
*/
#define LIBCURL_TIMESTAMP "2024-09-18"
#define LIBCURL_TIMESTAMP "2024-12-11"

#define CURL_VERSION_BITS(x,y,z) ((x)<<16|(y)<<8|(z))
#define CURL_AT_LEAST_VERSION(x,y,z) \
Expand Down
18 changes: 7 additions & 11 deletions ktor-client/ktor-client-curl/desktop/interop/include/curl/multi.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,7 @@
extern "C" {
#endif

#if defined(BUILDING_LIBCURL) || defined(CURL_STRICTER)
typedef struct Curl_multi CURLM;
#else
typedef void CURLM;
#endif

typedef enum {
CURLM_CALL_MULTI_PERFORM = -1, /* please call curl_multi_perform() or
Expand Down Expand Up @@ -248,13 +244,13 @@ CURL_EXTERN CURLMcode curl_multi_cleanup(CURLM *multi_handle);
* The data the returned pointer points to will not survive calling
* curl_multi_cleanup().
*
* The 'CURLMsg' struct is meant to be very simple and only contain
* very basic information. If more involved information is wanted,
* we will provide the particular "transfer handle" in that struct
* and that should/could/would be used in subsequent
* curl_easy_getinfo() calls (or similar). The point being that we
* must never expose complex structs to applications, as then we will
* undoubtably get backwards compatibility problems in the future.
* The 'CURLMsg' struct is meant to be simple and only contain basic
* information. If more involved information is wanted, we will
* provide the particular "transfer handle" in that struct and that
* should/could/would be used in subsequent curl_easy_getinfo() calls
* (or similar). The point being that we must never expose complex
* structs to applications, as then we will undoubtably get backwards
* compatibility problems in the future.
*
* Returns: A pointer to a filled-in struct, or NULL if it failed or ran out
* of structs. It also writes the number of messages left in the
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified ktor-client/ktor-client-curl/desktop/interop/lib/mingwX64/libz.a
Binary file not shown.

0 comments on commit 81eae75

Please sign in to comment.