mirror of
https://github.com/curl/curl.git
synced 2026-06-08 06:14:17 +03:00
CURLOPT_REDIR_PROTOCOLS.md add history, drop cast
This commit is contained in:
parent
7ca1aae9f7
commit
6088b7bf3b
1 changed files with 6 additions and 1 deletions
|
|
@ -97,7 +97,7 @@ int main(int argc, char **argv)
|
|||
curl_easy_setopt(curl, CURLOPT_URL, argv[1]);
|
||||
|
||||
/* only allow redirects to HTTP and HTTPS URLs */
|
||||
curl_easy_setopt(curl, CURLOPT_REDIR_PROTOCOLS, (long)
|
||||
curl_easy_setopt(curl, CURLOPT_REDIR_PROTOCOLS,
|
||||
CURLPROTO_HTTP | CURLPROTO_HTTPS);
|
||||
|
||||
/* Perform the request */
|
||||
|
|
@ -106,6 +106,11 @@ int main(int argc, char **argv)
|
|||
}
|
||||
~~~
|
||||
|
||||
# HISTORY
|
||||
|
||||
**CURLPROTO_*** macros became `long` types in 8.16.0, prior to this version
|
||||
a `long` cast was necessary when passed to curl_easy_setopt(3).
|
||||
|
||||
# DEPRECATED
|
||||
|
||||
Deprecated since 7.85.0.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue