code: curl_easy_init() вывод

master
MokeevNV 2 недель назад
Родитель ec76b9b87f
Сommit 3661824652

@ -42,16 +42,19 @@ Input input_data(istream& in, bool promt = false) {
int main(int argc, char* argv[]) {
curl_global_init(CURL_GLOBAL_ALL);
if(argc > 1) {
cout << "argc = " << argc << endl;
for(int i = 0; i < argc; i++){
cout << "argv[" << i << "] = " << argv[i] << endl;
CURL *curl = curl_easy_init();
if(curl) {
CURLcode res;
curl_easy_setopt(curl, CURLOPT_URL, argv[1]);
res = curl_easy_perform(curl);
curl_easy_cleanup(curl);
}
return 0;
}
curl_global_init(CURL_GLOBAL_ALL);
auto in = input_data(cin);
auto bins = make_histogram(in.numbers, in.bin_count);
show_histogram_svg(bins);

Загрузка…
Отмена
Сохранить