mirror of
https://github.com/curl/curl.git
synced 2026-06-08 08:35:24 +03:00
CURLOPT_PROXYTYPE.md drop cast, add note to history
This commit is contained in:
parent
bee5b178bc
commit
1530bd2b5b
1 changed files with 6 additions and 1 deletions
|
|
@ -85,13 +85,18 @@ int main(void)
|
|||
curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/");
|
||||
curl_easy_setopt(curl, CURLOPT_PROXY, "local.example.com:1080");
|
||||
/* set the proxy type */
|
||||
curl_easy_setopt(curl, CURLOPT_PROXYTYPE, (long)CURLPROXY_SOCKS5);
|
||||
curl_easy_setopt(curl, CURLOPT_PROXYTYPE, CURLPROXY_SOCKS5);
|
||||
ret = curl_easy_perform(curl);
|
||||
curl_easy_cleanup(curl);
|
||||
}
|
||||
}
|
||||
~~~
|
||||
|
||||
# HISTORY
|
||||
|
||||
CURLPROXY_\* enums became `long` types in 8.16.0, prior to this version
|
||||
a `long` cast is necessary when passing to curl_easy_setopt(3).
|
||||
|
||||
# %AVAILABILITY%
|
||||
|
||||
# RETURN VALUE
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue