diff --git a/rdrand.cpp b/rdrand.cpp index d18f3bd0..f3b586a9 100644 --- a/rdrand.cpp +++ b/rdrand.cpp @@ -7,10 +7,6 @@ #include "rdrand.h" #include "cpu.h" -#if CRYPTOPP_MSC_VERSION -# pragma warning(disable: 4100) -#endif - // This file (and friends) provides both RDRAND and RDSEED. They were added at // Crypto++ 5.6.3. At compile time, it uses CRYPTOPP_BOOL_{X86|X32|X64} // to select an implementation or "throw NotImplemented". The class does not @@ -158,6 +154,7 @@ inline void RDRAND32(void* output) while(!_rdrand32_step(reinterpret_cast(output))) {} #else // RDRAND not detected at compile time, or no suitable compiler found + CRYPTOPP_UNUSED(output); throw NotImplemented("RDRAND: failed to find an implementation"); #endif } @@ -199,6 +196,7 @@ inline void RDRAND64(void* output) while(!_rdrand64_step(reinterpret_cast(output))) {} #else // RDRAND not detected at compile time, or no suitable compiler found + CRYPTOPP_UNUSED(output); throw NotImplemented("RDRAND: failed to find an implementation"); #endif } @@ -253,6 +251,7 @@ void RDRAND::GenerateBlock(byte *output, size_t size) } #else // RDRAND not detected at compile time, or no suitable compiler found + CRYPTOPP_UNUSED(output); throw NotImplemented("RDRAND: failed to find a suitable implementation"); #endif } @@ -312,6 +311,7 @@ inline void RDSEED32(void* output) while(!_rdseed32_step(reinterpret_cast(output))) {} #else // RDSEED not detected at compile time, or no suitable compiler found + CRYPTOPP_UNUSED(output); throw NotImplemented("RDSEED: failed to find an implementation"); #endif } @@ -353,6 +353,7 @@ inline void RDSEED64(void* output) while(!_rdseed64_step(reinterpret_cast(output))) {} #else // RDSEED not detected at compile time, or no suitable compiler found + CRYPTOPP_UNUSED(output); throw NotImplemented("RDSEED: failed to find an implementation"); #endif }