From ca7de45c500c7cefe539c25f9e7f847b0431fee2 Mon Sep 17 00:00:00 2001 From: "Igor (ZharkovIG)" Date: Mon, 28 Oct 2024 00:33:11 +0300 Subject: [PATCH] code: fix2 --- main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.cpp b/main.cpp index 99dfaeb..b3e525c 100644 --- a/main.cpp +++ b/main.cpp @@ -52,7 +52,7 @@ download(const string& address) { curl_easy_setopt(curl, CURLOPT_WRITEDATA, &buffer); res = curl_easy_perform(curl); curl_easy_cleanup(curl); - if (!res){ + if (res != CURLE_OK){ curl_off_t speed; res1 = curl_easy_getinfo(curl, CURLINFO_SPEED_DOWNLOAD_T, &speed); if(!res1){