From 88834998dda00a713abe3a17d6caebba2f70318d Mon Sep 17 00:00:00 2001 From: Todd Short Date: Wed, 31 Jan 2018 16:20:52 -0500 Subject: [PATCH] Free pha_dgst in SSL_clear() Reviewed-by: Ben Kaduk Reviewed-by: Matt Caswell (Merged from https://github.com/openssl/openssl/pull/4964) --- ssl/ssl_lib.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 5a5fbad1f6..68a9b19087 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -614,6 +614,9 @@ int SSL_clear(SSL *s) s->key_update = SSL_KEY_UPDATE_NONE; + EVP_MD_CTX_free(s->pha_dgst); + s->pha_dgst = NULL; + /* Reset DANE verification result state */ s->dane.mdpth = -1; s->dane.pdpth = -1; -- 2.39.2