From 59cfe1d4902cbbdae76b12367ac80df8a96a9983 Mon Sep 17 00:00:00 2001 From: Hans Nilsson Date: Wed, 20 Mar 2019 09:45:47 +0100 Subject: crypto: Fixup the ripemd160 macro chaos --- lib/crypto/c_src/hash.c | 2 +- lib/crypto/c_src/openssl_config.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/crypto/c_src/hash.c b/lib/crypto/c_src/hash.c index 329b9b64e5..9b79258585 100644 --- a/lib/crypto/c_src/hash.c +++ b/lib/crypto/c_src/hash.c @@ -478,7 +478,7 @@ ERL_NIF_TERM hash_final_nif(ErlNifEnv* env, int argc, const ERL_NIF_TERM argv[]) ctx_final = (final_fun)(&MD5_Final); break; #endif -#ifdef HAVE_MD5 +#ifdef HAVE_RIPEMD160 case NID_ripemd160: ctx_size = RIPEMD160_CTX_LEN; ctx_final = (final_fun)(&RIPEMD160_Final); diff --git a/lib/crypto/c_src/openssl_config.h b/lib/crypto/c_src/openssl_config.h index ea2c0a2cfb..f926f8af13 100644 --- a/lib/crypto/c_src/openssl_config.h +++ b/lib/crypto/c_src/openssl_config.h @@ -183,7 +183,8 @@ #endif #ifndef OPENSSL_NO_RMD160 -# define HAVE_RMD160 +/* Note RMD160 vs RIPEMD160 */ +# define HAVE_RIPEMD160 #endif -- cgit v1.2.3