comparison src/services/anilist.cpp @ 48:e613772f41d5

statistics.cpp: show requests made
author Paper <mrpapersonic@gmail.com>
date Mon, 25 Sep 2023 01:07:22 -0400
parents d8eb763e6661
children 0c4138de2ea7
comparison
equal deleted inserted replaced
47:d8eb763e6661 48:e613772f41d5
57 curl_easy_setopt(curl, CURLOPT_WRITEDATA, &userdata); 57 curl_easy_setopt(curl, CURLOPT_WRITEDATA, &userdata);
58 curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, &CurlWriteCallback); 58 curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, &CurlWriteCallback);
59 /* Use system certs... useful on Windows. */ 59 /* Use system certs... useful on Windows. */
60 curl_easy_setopt(curl, CURLOPT_SSL_OPTIONS, CURLSSLOPT_NATIVE_CA); 60 curl_easy_setopt(curl, CURLOPT_SSL_OPTIONS, CURLSSLOPT_NATIVE_CA);
61 CURLcode res = curl_easy_perform(curl); 61 CURLcode res = curl_easy_perform(curl);
62 session.IncrementRequests();
62 curl_slist_free_all(list); 63 curl_slist_free_all(list);
63 curl_easy_cleanup(curl); 64 curl_easy_cleanup(curl);
64 if (res != CURLE_OK) { 65 if (res != CURLE_OK) {
65 QMessageBox box(QMessageBox::Icon::Critical, "", 66 QMessageBox box(QMessageBox::Icon::Critical, "",
66 QString("curl_easy_perform(curl) failed!: ") + QString(curl_easy_strerror(res))); 67 QString("curl_easy_perform(curl) failed!: ") + QString(curl_easy_strerror(res)));