summarylogtreecommitdiffstats
path: root/curl-ptr.patch
diff options
context:
space:
mode:
authorArthur Zamarin2016-08-05 12:09:09 +0300
committerArthur Zamarin2016-08-05 12:09:09 +0300
commit5bb8c2d501233f354578ad390660cdac608d80f9 (patch)
treec804441350a56be25e39a74164c3447897ef459d /curl-ptr.patch
parentbb434ffa6c95496624d083fd32df87b03e78e8a4 (diff)
downloadaur-5bb8c2d501233f354578ad390660cdac608d80f9.tar.gz
fix compile
Diffstat (limited to 'curl-ptr.patch')
-rw-r--r--curl-ptr.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/curl-ptr.patch b/curl-ptr.patch
new file mode 100644
index 00000000000..26ccfad27a9
--- /dev/null
+++ b/curl-ptr.patch
@@ -0,0 +1,35 @@
+diff -ru a/lib/warmux/net/download.cpp b/lib/warmux/net/download.cpp
+--- a/lib/warmux/net/download.cpp 2016-08-05 11:57:19.524227773 +0300
++++ b/lib/warmux/net/download.cpp 2016-08-05 12:01:13.534472330 +0300
+@@ -47,24 +47,24 @@
+ #endif
+
+ curl = curl_easy_init();
+- curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, download_callback);
++ curl_easy_setopt((CURL*)curl, CURLOPT_WRITEFUNCTION, download_callback);
+ curl_error_buf = new char[CURL_ERROR_SIZE];
+- curl_easy_setopt(curl, CURLOPT_ERRORBUFFER, curl_error_buf);
+- curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1);
++ curl_easy_setopt((CURL*)curl, CURLOPT_ERRORBUFFER, curl_error_buf);
++ curl_easy_setopt((CURL*)curl, CURLOPT_FOLLOWLOCATION, 1);
+ }
+
+ Downloader::~Downloader()
+ {
+- curl_easy_cleanup(curl);
++ curl_easy_cleanup((CURL*)curl);
+ curl_global_cleanup();
+ delete[] curl_error_buf;
+ }
+
+ bool Downloader::Get(const char* url, FILE* file)
+ {
+- curl_easy_setopt(curl, CURLOPT_FILE, file);
+- curl_easy_setopt(curl, CURLOPT_URL, url);
+- CURLcode r = curl_easy_perform(curl);
++ curl_easy_setopt((CURL*)curl, CURLOPT_FILE, file);
++ curl_easy_setopt((CURL*)curl, CURLOPT_URL, url);
++ CURLcode r = curl_easy_perform((CURL*)curl);
+ fflush(file);
+
+ if (r == CURLE_OK)