mirror of
https://github.com/curl/curl.git
synced 2026-08-25 09:13:31 +03:00
CURLOPT: bump CURLPROXY_* enums to long, drop casts
This patch bumps the size of these macros from `int` to `long`, while keeping their actual values the same. It may cause incompatibilities in user code, requiring the bump of holder variables and/or adding casts: - CURLPROXY_HTTP - CURLPROXY_HTTP_1_0 - CURLPROXY_HTTPS - CURLPROXY_HTTPS2 - CURLPROXY_SOCKS4 - CURLPROXY_SOCKS4A - CURLPROXY_SOCKS5 - CURLPROXY_SOCKS5_HOSTNAME Also: - keep existing cast within the documentation to make sure it applies to older curl versions as well. Closes #18054
This commit is contained in:
parent
d45b85d791
commit
1a12663d06
10 changed files with 28 additions and 25 deletions
|
|
@ -78,7 +78,7 @@ static CURLcode test_lib1525(char *URL)
|
|||
test_setopt(curl, CURLOPT_POST, 0L);
|
||||
test_setopt(curl, CURLOPT_UPLOAD, 1L);
|
||||
test_setopt(curl, CURLOPT_VERBOSE, 1L);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, (long)CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_HEADER, 1L);
|
||||
test_setopt(curl, CURLOPT_WRITEFUNCTION, fwrite);
|
||||
test_setopt(curl, CURLOPT_READFUNCTION, t1525_read_cb);
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ static CURLcode test_lib1526(char *URL)
|
|||
test_setopt(curl, CURLOPT_POST, 0L);
|
||||
test_setopt(curl, CURLOPT_UPLOAD, 1L);
|
||||
test_setopt(curl, CURLOPT_VERBOSE, 1L);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, (long)CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_HEADER, 1L);
|
||||
test_setopt(curl, CURLOPT_WRITEFUNCTION, fwrite);
|
||||
test_setopt(curl, CURLOPT_READFUNCTION, t1526_read_cb);
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ static CURLcode test_lib1527(char *URL)
|
|||
test_setopt(curl, CURLOPT_POST, 0L);
|
||||
test_setopt(curl, CURLOPT_UPLOAD, 1L);
|
||||
test_setopt(curl, CURLOPT_VERBOSE, 1L);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, (long)CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_HEADER, 1L);
|
||||
test_setopt(curl, CURLOPT_WRITEFUNCTION, fwrite);
|
||||
test_setopt(curl, CURLOPT_READFUNCTION, t1527_read_cb);
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ static CURLcode test_lib1528(char *URL)
|
|||
test_setopt(curl, CURLOPT_PROXYHEADER, phl);
|
||||
test_setopt(curl, CURLOPT_HEADEROPT, (long)CURLHEADER_SEPARATE);
|
||||
test_setopt(curl, CURLOPT_VERBOSE, 1L);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, (long)CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_HEADER, 1L);
|
||||
|
||||
res = curl_easy_perform(curl);
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ static CURLcode test_lib1529(char *URL)
|
|||
test_setopt(curl, CURLOPT_URL, bURL);
|
||||
test_setopt(curl, CURLOPT_PROXY, libtest_arg2);
|
||||
test_setopt(curl, CURLOPT_VERBOSE, 1L);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, (long)CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_PROXYTYPE, CURLPROXY_HTTP);
|
||||
test_setopt(curl, CURLOPT_HEADER, 1L);
|
||||
|
||||
res = curl_easy_perform(curl);
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ static CURLcode test_lib564(char *URL)
|
|||
easy_setopt(curl, CURLOPT_URL, URL);
|
||||
easy_setopt(curl, CURLOPT_VERBOSE, 1L);
|
||||
easy_setopt(curl, CURLOPT_PROXY, libtest_arg2);
|
||||
easy_setopt(curl, CURLOPT_PROXYTYPE, (long)CURLPROXY_SOCKS4);
|
||||
easy_setopt(curl, CURLOPT_PROXYTYPE, CURLPROXY_SOCKS4);
|
||||
|
||||
multi_init(m);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue