diff options
author | Jay Satiro <raysatiro@yahoo.com> | 2017-11-04 18:36:07 -0400 |
---|---|---|
committer | Jay Satiro <raysatiro@yahoo.com> | 2017-11-04 18:36:07 -0400 |
commit | 462f3cac34c09b9c28b449258e71dc37171dc604 (patch) | |
tree | c2d881ba50e6ede08c4c77585c25731269d0d8e1 /lib | |
parent | 685ef130575cdcf63fe9547757d88a49a40ef281 (diff) |
url: remove arg value check from CURLOPT_SSH_AUTH_TYPES
Since CURLSSH_AUTH_ANY (aka CURLSSH_AUTH_DEFAULT) is ~0 an arg value
check on this option is incorrect; we have to accept any value.
Prior to this change since f121575 (7.56.1+) CURLOPT_SSH_AUTH_TYPES
erroneously rejected CURLSSH_AUTH_ANY with CURLE_BAD_FUNCTION_ARGUMENT.
Bug: https://github.com/curl/curl/commit/f121575#commitcomment-25347120
Diffstat (limited to 'lib')
-rw-r--r-- | lib/url.c | 5 |
1 files changed, 1 insertions, 4 deletions
@@ -2710,10 +2710,7 @@ CURLcode Curl_setopt(struct Curl_easy *data, CURLoption option, #ifdef USE_LIBSSH2 /* we only include SSH options if explicitly built to support SSH */ case CURLOPT_SSH_AUTH_TYPES: - arg = va_arg(param, long); - if(arg < CURLSSH_AUTH_NONE) - return CURLE_BAD_FUNCTION_ARGUMENT; - data->set.ssh_auth_types = arg; + data->set.ssh_auth_types = va_arg(param, long); break; case CURLOPT_SSH_PUBLIC_KEYFILE: |