обработка ошибок

Этот коммит содержится в:
BubnovAS
2025-06-02 11:19:32 +03:00
родитель b78d8b7ce8
Коммит 8a1f6ebd2f

Просмотреть файл

@@ -41,6 +41,10 @@ int main(int argc, char* argv[]) {
CURLcode res;
curl_easy_setopt(curl, CURLOPT_URL, argv[1]);
res = curl_easy_perform(curl);
if (res != CURLE_OK){
cerr << curl_easy_strerror(res);
exit(1);
}
curl_easy_cleanup(curl);
}
}