[sr-dev] git:master:bab289f3: http_client: cast parameter to curl function to avoid warnings

Daniel-Constantin Mierla miconda at gmail.com
Fri Jan 5 09:09:17 CET 2018


Module: kamailio
Branch: master
Commit: bab289f36b189a2836ef51acc9e26aed422a7dad
URL: https://github.com/kamailio/kamailio/commit/bab289f36b189a2836ef51acc9e26aed422a7dad

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2018-01-05T09:08:56+01:00

http_client: cast parameter to curl function to avoid warnings

---

Modified: src/modules/http_client/functions.c

---

Diff:  https://github.com/kamailio/kamailio/commit/bab289f36b189a2836ef51acc9e26aed422a7dad.diff
Patch: https://github.com/kamailio/kamailio/commit/bab289f36b189a2836ef51acc9e26aed422a7dad.patch

---

diff --git a/src/modules/http_client/functions.c b/src/modules/http_client/functions.c
index 68ed33b248..695324bf43 100644
--- a/src/modules/http_client/functions.c
+++ b/src/modules/http_client/functions.c
@@ -252,7 +252,7 @@ static int curL_query_url(struct sip_msg *_m, const char *_url, str *_dst,
 
 
 	res |= curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_function);
-	res |= curl_easy_setopt(curl, CURLOPT_WRITEDATA, &stream);
+	res |= curl_easy_setopt(curl, CURLOPT_WRITEDATA, (void*)(&stream));
 
 	if(params->useragent)
 		res |= curl_easy_setopt(curl, CURLOPT_USERAGENT, params->useragent);




More information about the sr-dev mailing list