|
|
|
@ -40,7 +40,6 @@ Input download(const string& address) {
|
|
|
|
|
if (curl) {
|
|
|
|
|
CURLcode res;
|
|
|
|
|
curl_easy_setopt(curl, CURLOPT_URL, address.c_str());
|
|
|
|
|
curl_easy_setopt(curl, CURLOPT_NOPROGRESS, 0L);
|
|
|
|
|
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
|
|
|
|
|
curl_easy_setopt(curl, CURLOPT_WRITEDATA, &buffer);
|
|
|
|
|
res = curl_easy_perform(curl);
|
|
|
|
@ -51,7 +50,8 @@ Input download(const string& address) {
|
|
|
|
|
auto data = curl_version_info(CURLVERSION_NOW)->protocols;
|
|
|
|
|
for (auto protocol = data; *protocol; ++protocol) {
|
|
|
|
|
cerr << *protocol << endl;
|
|
|
|
|
} curl_easy_cleanup(curl);
|
|
|
|
|
}
|
|
|
|
|
curl_easy_cleanup(curl);
|
|
|
|
|
}
|
|
|
|
|
return input_data(buffer);
|
|
|
|
|
}
|
|
|
|
|