code: curl_easy_init
Этот коммит содержится в:
13
labor01.cpp
13
labor01.cpp
@@ -42,14 +42,17 @@ input_data(istream& inn, bool promt) {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char* argv[]) {
|
int main(int argc, char* argv[1]) {
|
||||||
if (argc > 1) {
|
if (argc > 1) {
|
||||||
cout << argc << "\n";
|
CURL* curl = curl_easy_init();
|
||||||
for (int i = 0; i < argc; i++) {
|
if (curl) {
|
||||||
cout << "argv[" << i << "] = " << argv[i] << "\n";
|
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);
|
|
||||||
bool promt = true;
|
bool promt = true;
|
||||||
auto in = input_data(cin, promt);
|
auto in = input_data(cin, promt);
|
||||||
auto bins = make_histogram(in.numbers, in.bin_count);
|
auto bins = make_histogram(in.numbers, in.bin_count);
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user