From 1451f4d2e18ec0ca55c1d3c4401a9c83d45c00f3 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Wed, 16 Dec 2020 09:24:16 +0100 Subject: examples: remove superfluous asterisk uses ... for function pointers. Breaks in ancient compilers. --- docs/examples/cacertinmem.c | 6 +++--- docs/examples/synctime.c | 4 ++-- docs/examples/usercertinmem.c | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/examples/cacertinmem.c b/docs/examples/cacertinmem.c index dd9bb0677..880b7b1fd 100644 --- a/docs/examples/cacertinmem.c +++ b/docs/examples/cacertinmem.c @@ -129,9 +129,9 @@ int main(void) curl_easy_setopt(ch, CURLOPT_HEADER, 0L); curl_easy_setopt(ch, CURLOPT_NOPROGRESS, 1L); curl_easy_setopt(ch, CURLOPT_NOSIGNAL, 1L); - curl_easy_setopt(ch, CURLOPT_WRITEFUNCTION, *writefunction); + curl_easy_setopt(ch, CURLOPT_WRITEFUNCTION, writefunction); curl_easy_setopt(ch, CURLOPT_WRITEDATA, stdout); - curl_easy_setopt(ch, CURLOPT_HEADERFUNCTION, *writefunction); + curl_easy_setopt(ch, CURLOPT_HEADERFUNCTION, writefunction); curl_easy_setopt(ch, CURLOPT_HEADERDATA, stderr); curl_easy_setopt(ch, CURLOPT_SSLCERTTYPE, "PEM"); curl_easy_setopt(ch, CURLOPT_SSL_VERIFYPEER, 1L); @@ -168,7 +168,7 @@ int main(void) * load the certificate by installing a function doing the necessary * "modifications" to the SSL CONTEXT just before link init */ - curl_easy_setopt(ch, CURLOPT_SSL_CTX_FUNCTION, *sslctx_function); + curl_easy_setopt(ch, CURLOPT_SSL_CTX_FUNCTION, sslctx_function); rv = curl_easy_perform(ch); if(rv == CURLE_OK) printf("*** transfer succeeded ***\n"); diff --git a/docs/examples/synctime.c b/docs/examples/synctime.c index 180ab1a7c..b6b77268e 100644 --- a/docs/examples/synctime.c +++ b/docs/examples/synctime.c @@ -198,8 +198,8 @@ void SyncTime_CURL_Init(CURL *curl, char *proxy_port, #ifdef SYNCTIME_UA curl_easy_setopt(curl, CURLOPT_USERAGENT, SYNCTIME_UA); #endif - curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, *SyncTime_CURL_WriteOutput); - curl_easy_setopt(curl, CURLOPT_HEADERFUNCTION, *SyncTime_CURL_WriteHeader); + curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, SyncTime_CURL_WriteOutput); + curl_easy_setopt(curl, CURLOPT_HEADERFUNCTION, SyncTime_CURL_WriteHeader); } int SyncTime_CURL_Fetch(CURL *curl, char *URL_Str, char *OutFileName, diff --git a/docs/examples/usercertinmem.c b/docs/examples/usercertinmem.c index dcfecd3ad..35218bdc2 100644 --- a/docs/examples/usercertinmem.c +++ b/docs/examples/usercertinmem.c @@ -211,7 +211,7 @@ int main(void) * load the certificate and key by installing a function doing the necessary * "modifications" to the SSL CONTEXT just before link init */ - curl_easy_setopt(ch, CURLOPT_SSL_CTX_FUNCTION, *sslctx_function); + curl_easy_setopt(ch, CURLOPT_SSL_CTX_FUNCTION, sslctx_function); rv = curl_easy_perform(ch); if(rv == CURLE_OK) { printf("*** transfer succeeded ***\n"); -- cgit v1.2.1