code: загрузка файла по сети
Этот коммит содержится в:
9
main.cpp
9
main.cpp
@@ -46,9 +46,14 @@ input_data(istream& in, bool prompt) {
|
||||
|
||||
int
|
||||
main(int argc, char* argv[]){
|
||||
CURL *curl = curl_easy_init();
|
||||
if (argc>1){
|
||||
cout << argc;
|
||||
cout << argv[0];
|
||||
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);
|
||||
|
||||
Ссылка в новой задаче
Block a user