aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/hmac
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2015-12-02 22:49:24 +0100
committerRichard Levitte <levitte@openssl.org>2015-12-07 17:40:20 +0100
commita87a0a6e5eb7993ae7a4d2eb13e605d8b5428073 (patch)
treee79f2c2eb1e46559b9b84d28318a8d3ed43d820b /crypto/hmac
parentdc0099e1dd013abe52d0ff4901e02cca030bec97 (diff)
downloadopenssl-a87a0a6e5eb7993ae7a4d2eb13e605d8b5428073.tar.gz
Cleanup: fix all sources that used HMAC_CTX_init
Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'crypto/hmac')
-rw-r--r--crypto/hmac/hmac.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/hmac/hmac.c b/crypto/hmac/hmac.c
index c0f45131fa..3bc93a8841 100644
--- a/crypto/hmac/hmac.c
+++ b/crypto/hmac/hmac.c
@@ -131,7 +131,7 @@ int HMAC_Init_ex(HMAC_CTX *ctx, const void *key, int len,
int HMAC_Init(HMAC_CTX *ctx, const void *key, int len, const EVP_MD *md)
{
if (key && md)
- HMAC_CTX_init(ctx);
+ HMAC_CTX_reset(ctx);
return HMAC_Init_ex(ctx, key, len, md, NULL);
}
#endif
@@ -225,7 +225,7 @@ int HMAC_CTX_reset(HMAC_CTX *ctx)
int HMAC_CTX_copy(HMAC_CTX *dctx, HMAC_CTX *sctx)
{
- if (!HMAC_CTX_init(dctx))
+ if (!HMAC_CTX_reset(dctx))
goto err;
if (!EVP_MD_CTX_copy_ex(dctx->i_ctx, sctx->i_ctx))
goto err;