From: Otto Moerbeek Date: Tue, 15 Apr 2025 13:09:27 +0000 (+0200) Subject: dnsdist: a few more cases of potentiually unused args X-Git-Tag: dnsdist-2.0.0-alpha2~72^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dfdb8c324a3405aafbeb76eaad56b265b5ba6405;p=thirdparty%2Fpdns.git dnsdist: a few more cases of potentiually unused args --- diff --git a/pdns/libssl.cc b/pdns/libssl.cc index 8b7b3e5de2..548f714111 100644 --- a/pdns/libssl.cc +++ b/pdns/libssl.cc @@ -1110,7 +1110,7 @@ static void libssl_key_log_file_callback(const SSL* ssl, const char* line) } #endif /* HAVE_SSL_CTX_SET_KEYLOG_CALLBACK */ -pdns::UniqueFilePtr libssl_set_key_log_file(SSL_CTX* ctx, const std::string& logFile) +pdns::UniqueFilePtr libssl_set_key_log_file([[maybe_unused]] SSL_CTX* ctx, [[maybe_unused]] const std::string& logFile) { #ifdef HAVE_SSL_CTX_SET_KEYLOG_CALLBACK auto filePtr = pdns::openFileForWriting(logFile, 0600, false, true); @@ -1127,14 +1127,14 @@ pdns::UniqueFilePtr libssl_set_key_log_file(SSL_CTX* ctx, const std::string& log } /* called in a client context, if the client advertised more than one ALPN value and the server returned more than one as well, to select the one to use. */ -void libssl_set_alpn_select_callback(SSL_CTX* ctx, int (*cb)(SSL* s, const unsigned char** out, unsigned char* outlen, const unsigned char* in, unsigned int inlen, void* arg), void* arg) +void libssl_set_alpn_select_callback([[maybe_unused]] SSL_CTX* ctx, [[maybe_unused]] int (*cb)(SSL* s, const unsigned char** out, unsigned char* outlen, const unsigned char* in, unsigned int inlen, void* arg), [[maybe_unused]] void* arg) { #ifdef HAVE_SSL_CTX_SET_ALPN_SELECT_CB SSL_CTX_set_alpn_select_cb(ctx, cb, arg); #endif } -bool libssl_set_alpn_protos(SSL_CTX* ctx, const std::vector>& protos) +bool libssl_set_alpn_protos([[maybe_unused]] SSL_CTX* ctx, [[maybe_unused]] const std::vector>& protos) { #ifdef HAVE_SSL_CTX_SET_ALPN_PROTOS std::vector wire;