]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
tool: fix --capath when proxy support is disabled
authorLoïc Yhuel <loic.yhuel@softathome.com>
Wed, 11 Oct 2023 11:09:23 +0000 (13:09 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Sat, 21 Oct 2023 12:52:47 +0000 (14:52 +0200)
After 95e8515ca0, --capath always sets CURLOPT_PROXY_CAPATH, which fails
with CURLE_UNKNOWN_OPTION when proxy support is disabled.

Closes #12089

src/tool_operate.c

index b60f57e0d96ba45b4363e615916d89480a68fe2e..697b64e38a220d42b931b10becd550b87e5bff4e 100644 (file)
@@ -1776,7 +1776,8 @@ static CURLcode single_transfer(struct GlobalConfig *global,
                                   (config->proxy_capath ?
                                    config->proxy_capath :
                                    config->capath));
-          if(result == CURLE_NOT_BUILT_IN) {
+          if((result == CURLE_NOT_BUILT_IN) ||
+             (result == CURLE_UNKNOWN_OPTION)) {
             if(config->proxy_capath) {
               warnf(global,
                     "ignoring --proxy-capath, not supported by libcurl");