Mercurial > minori
diff src/core/http.cc @ 175:9b10175be389
dep/json: update to v3.11.3
anime/db: save anime list to database, very much untested and likely won't work as intended
author | Paper <mrpapersonic@gmail.com> |
---|---|
date | Thu, 30 Nov 2023 13:52:26 -0500 |
parents | f5940a575d83 |
children | 53211cb1e7f5 |
line wrap: on
line diff
--- a/src/core/http.cc Wed Nov 29 13:53:56 2023 -0500 +++ b/src/core/http.cc Thu Nov 30 13:52:26 2023 -0500 @@ -1,10 +1,10 @@ #include "core/http.h" #include "core/session.h" #include <QByteArray> -#include <QMessageBox> #include <curl/curl.h> #include <string> #include <vector> +#include <iostream> namespace HTTP { @@ -31,11 +31,8 @@ CURLcode res = curl_easy_perform(curl); session.IncrementRequests(); curl_easy_cleanup(curl); - if (res != CURLE_OK) { - QMessageBox box(QMessageBox::Icon::Critical, "", - QString("curl_easy_perform(curl) failed!: ") + QString(curl_easy_strerror(res))); - box.exec(); - } + if (res != CURLE_OK) + std::cerr << "curl_easy_perform(curl) failed!: " << curl_easy_strerror(res) << std::endl; } return userdata; } @@ -59,11 +56,8 @@ CURLcode res = curl_easy_perform(curl); session.IncrementRequests(); curl_easy_cleanup(curl); - if (res != CURLE_OK) { - QMessageBox box(QMessageBox::Icon::Critical, "", - QString("curl_easy_perform(curl) failed!: ") + QString(curl_easy_strerror(res))); - box.exec(); - } + if (res != CURLE_OK) + std::cerr << "curl_easy_perform(curl) failed!: " << curl_easy_strerror(res) << std::endl; } return userdata; }