mirror of
https://github.com/curl/curl.git
synced 2026-08-05 04:36:14 +03:00
curl: make --libcurl output better CURLOPT_*SSLVERSION
The option is really two enums ORed together, so it needs special attention to make the code output nice. Added test 1481 to verify. Both the server and the proxy versions. Reported-by: Boris Verkhovskiy Fixes #13127 Closes #13129
This commit is contained in:
parent
09f367977a
commit
40948189ff
5 changed files with 187 additions and 5 deletions
|
|
@ -52,6 +52,7 @@ extern const struct NameValue setopt_nv_CURLPROXY[];
|
|||
extern const struct NameValue setopt_nv_CURL_SOCKS_PROXY[];
|
||||
extern const struct NameValue setopt_nv_CURL_HTTP_VERSION[];
|
||||
extern const struct NameValue setopt_nv_CURL_SSLVERSION[];
|
||||
extern const struct NameValue setopt_nv_CURL_SSLVERSION_MAX[];
|
||||
extern const struct NameValue setopt_nv_CURL_TIMECOND[];
|
||||
extern const struct NameValue setopt_nv_CURLFTPSSL_CCC[];
|
||||
extern const struct NameValue setopt_nv_CURLUSESSL[];
|
||||
|
|
@ -81,6 +82,9 @@ extern const struct NameValueUnsigned setopt_nv_CURLHSTS[];
|
|||
CURLcode tool_setopt_enum(CURL *curl, struct GlobalConfig *config,
|
||||
const char *name, CURLoption tag,
|
||||
const struct NameValue *nv, long lval);
|
||||
CURLcode tool_setopt_SSLVERSION(CURL *curl, struct GlobalConfig *config,
|
||||
const char *name, CURLoption tag,
|
||||
long lval);
|
||||
CURLcode tool_setopt_flags(CURL *curl, struct GlobalConfig *config,
|
||||
const char *name, CURLoption tag,
|
||||
const struct NameValue *nv, long lval);
|
||||
|
|
@ -106,6 +110,9 @@ CURLcode tool_setopt(CURL *curl, bool str, struct GlobalConfig *global,
|
|||
#define my_setopt_enum(x,y,z) \
|
||||
SETOPT_CHECK(tool_setopt_enum(x, global, #y, y, setopt_nv_ ## y, z), y)
|
||||
|
||||
#define my_setopt_SSLVERSION(x,y,z) \
|
||||
SETOPT_CHECK(tool_setopt_SSLVERSION(x, global, #y, y, z), y)
|
||||
|
||||
#define my_setopt_bitmask(x,y,z) \
|
||||
SETOPT_CHECK(tool_setopt_bitmask(x, global, #y, y, setopt_nv_ ## y, z), y)
|
||||
|
||||
|
|
@ -132,6 +139,9 @@ CURLcode tool_setopt(CURL *curl, bool str, struct GlobalConfig *global,
|
|||
#define my_setopt_enum(x,y,z) \
|
||||
SETOPT_CHECK(curl_easy_setopt(x, y, z), y)
|
||||
|
||||
#define my_setopt_SSLVERSION(x,y,z) \
|
||||
SETOPT_CHECK(curl_easy_setopt(x, y, z), y)
|
||||
|
||||
#define my_setopt_bitmask(x,y,z) \
|
||||
SETOPT_CHECK(curl_easy_setopt(x, y, z), y)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue