I get "curl_easy_perform() failed: Unsupported protocol" for https requests:

Example:


#include <curl/curl.h>

int main(int argc, char** argv) {

    CURL* curl;
    CURLcode res;
    curl_global_init(CURL_GLOBAL_ALL);
    curl = curl_easy_init();

    if (curl) {
        curl_easy_setopt(curl, CURLOPT_URL, "https://www.google.com";);
        res = curl_easy_perform(curl);
        if (res != CURLE_OK)
            fprintf(stderr, "curl_easy_perform() failed: %s\n", curl_easy_strerror(res));

        curl_easy_cleanup(curl);
    }
    curl_global_cleanup();

    return 0;
}


And here is my problem with it: it works with the curl.exe executable I also built! Example:

$curl *https*://www.google.com

The *https *request WILL SUCCEED! -> connected through port 403 and the page contents are printed.

So why doesn't it work in my own sample project?

Here is my cmake SSL configuration:

-Julien
-- 
Unsubscribe: https://lists.haxx.se/listinfo/curl-library
Etiquette:   https://curl.haxx.se/mail/etiquette.html

Reply via email to