diff --git a/src/libsodium/crypto_generichash/blake2/ref/generichash_blake2b.c b/src/libsodium/crypto_generichash/blake2/ref/generichash_blake2b.c index 5382cbae..dfcfa19e 100644 --- a/src/libsodium/crypto_generichash/blake2/ref/generichash_blake2b.c +++ b/src/libsodium/crypto_generichash/blake2/ref/generichash_blake2b.c @@ -1,12 +1,11 @@ +#include #include #include #include "blake2.h" #include "crypto_generichash.h" -#define COMPILER_ASSERT(X) (void) sizeof(char[(X) ? 1 : -1]) - int crypto_generichash_blake2b(unsigned char *out, const unsigned char *in, const unsigned char *key, @@ -18,8 +17,8 @@ crypto_generichash_blake2b(unsigned char *out, const unsigned char *in, inlen > UINT64_MAX) { return -1; } - COMPILER_ASSERT(outlen <= UINT8_MAX); - COMPILER_ASSERT(keylen <= UINT8_MAX); + assert(outlen <= UINT8_MAX); + assert(keylen <= UINT8_MAX); return blake2b((uint8_t *) out, in, key, (uint8_t) outlen, inlen, (uint8_t) keylen);