projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Prepare EVP_MAC infrastructure for moving all MACs to providers
[openssl.git]
/
crypto
/
cmac
/
cm_ameth.c
diff --git
a/crypto/cmac/cm_ameth.c
b/crypto/cmac/cm_ameth.c
index ed513b113fbcf9c669063abe8860f3a811aadc51..b1ee0d3d2f1d5406a9b59c8dd15be31732c69591 100644
(file)
--- a/
crypto/cmac/cm_ameth.c
+++ b/
crypto/cmac/cm_ameth.c
@@
-25,7
+25,10
@@
static int cmac_size(const EVP_PKEY *pkey)
static void cmac_key_free(EVP_PKEY *pkey)
{
EVP_MAC_CTX *cmctx = EVP_PKEY_get0(pkey);
+ EVP_MAC *mac = cmctx == NULL ? NULL : EVP_MAC_CTX_mac(cmctx);
+
EVP_MAC_CTX_free(cmctx);
+ EVP_MAC_free(mac);
}
const EVP_PKEY_ASN1_METHOD cmac_asn1_meth = {