mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-03-05 15:05:48 +02:00
Add missing cryptoInit() in cryptoHmacOne().
If cryptoInit() had not already been called then EVP_get_digestbyname() would fail. This does not appear to be a problem currently because of call order. Also, newer versions of OpenSSL auto-initialize.
This commit is contained in:
parent
ea485e916b
commit
f4e6e6bd80
@ -237,6 +237,9 @@ cryptoHmacOne(const String *type, const Buffer *key, const Buffer *message)
|
||||
ASSERT(key != NULL);
|
||||
ASSERT(message != NULL);
|
||||
|
||||
// Init crypto subsystem
|
||||
cryptoInit();
|
||||
|
||||
const EVP_MD *hashType = EVP_get_digestbyname(strPtr(type));
|
||||
ASSERT(hashType != NULL);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user