From 887be8a3178386309a2b7cf356bf2933d9cd1068 Mon Sep 17 00:00:00 2001 From: Jack Lloyd Date: Fri, 27 Jan 2017 21:50:40 -0500 Subject: Add BOTAN_UNUSED in creator functions If all (say) stream ciphers are disabled, avoid unused arg warning. [ci skip] --- src/lib/block/block_cipher.cpp | 3 +++ src/lib/kdf/kdf.cpp | 3 +++ src/lib/mac/mac.cpp | 3 +++ src/lib/pbkdf/pbkdf.cpp | 3 +++ src/lib/stream/stream_cipher.cpp | 3 +++ 5 files changed, 15 insertions(+) (limited to 'src') diff --git a/src/lib/block/block_cipher.cpp b/src/lib/block/block_cipher.cpp index 750d01821..fa0ecad52 100644 --- a/src/lib/block/block_cipher.cpp +++ b/src/lib/block/block_cipher.cpp @@ -274,6 +274,9 @@ BlockCipher::create(const std::string& algo, } #endif + BOTAN_UNUSED(req); + BOTAN_UNUSED(provider); + return nullptr; } diff --git a/src/lib/kdf/kdf.cpp b/src/lib/kdf/kdf.cpp index 2fba1868e..0e9d840c1 100644 --- a/src/lib/kdf/kdf.cpp +++ b/src/lib/kdf/kdf.cpp @@ -200,6 +200,9 @@ std::unique_ptr KDF::create(const std::string& algo_spec, } #endif + BOTAN_UNUSED(req); + BOTAN_UNUSED(provider); + return nullptr; } diff --git a/src/lib/mac/mac.cpp b/src/lib/mac/mac.cpp index 3dfe753b7..c48deb24b 100644 --- a/src/lib/mac/mac.cpp +++ b/src/lib/mac/mac.cpp @@ -121,6 +121,9 @@ MessageAuthenticationCode::create(const std::string& algo_spec, } #endif + BOTAN_UNUSED(req); + BOTAN_UNUSED(provider); + return nullptr; } diff --git a/src/lib/pbkdf/pbkdf.cpp b/src/lib/pbkdf/pbkdf.cpp index d9479bd8d..8f72a9180 100644 --- a/src/lib/pbkdf/pbkdf.cpp +++ b/src/lib/pbkdf/pbkdf.cpp @@ -52,6 +52,9 @@ std::unique_ptr PBKDF::create(const std::string& algo_spec, } #endif + BOTAN_UNUSED(req); + BOTAN_UNUSED(provider); + return nullptr; } diff --git a/src/lib/stream/stream_cipher.cpp b/src/lib/stream/stream_cipher.cpp index dfe1fa69b..f33d68296 100644 --- a/src/lib/stream/stream_cipher.cpp +++ b/src/lib/stream/stream_cipher.cpp @@ -112,6 +112,9 @@ std::unique_ptr StreamCipher::create(const std::string& algo_spec, #endif + BOTAN_UNUSED(req); + BOTAN_UNUSED(provider); + return nullptr; } -- cgit v1.2.3