From 6d56bd8855ceb937fe2f6053698793b797d7e17b Mon Sep 17 00:00:00 2001 From: Hans Zandbelt Date: Mon, 16 Dec 2024 17:18:03 +0100 Subject: [PATCH] suppress coverity suspicious sizeof in CURLOPT_WRITEDATA and CURLOPT_HEADERDATA Signed-off-by: Hans Zandbelt --- src/http.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/http.c b/src/http.c index 8ff35127..67daba7d 100644 --- a/src/http.c +++ b/src/http.c @@ -752,12 +752,12 @@ static apr_byte_t oidc_http_request(request_rec *r, const char *url, const char /* setup the buffer where the response data will be written to */ OIDC_HTTP_CURL_SETOPT(CURLOPT_WRITEFUNCTION, oidc_http_response_data); // coverity[suspicious_sizeof] - OIDC_HTTP_CURL_SETOPT(CURLOPT_WRITEDATA, &d_buf); + OIDC_HTTP_CURL_SETOPT(CURLOPT_WRITEDATA, (void *)&d_buf); /* setup the buffer where the response headers will be written to */ OIDC_HTTP_CURL_SETOPT(CURLOPT_HEADERFUNCTION, oidc_http_response_header); // coverity[suspicious_sizeof] - OIDC_HTTP_CURL_SETOPT(CURLOPT_HEADERDATA, &h_buf); + OIDC_HTTP_CURL_SETOPT(CURLOPT_HEADERDATA, (void *)&h_buf); #ifndef LIBCURL_NO_CURLPROTO #if LIBCURL_VERSION_NUM >= 0x075500