From 3c38fa4b797848a76b83f91e423de470adbb3b61 Mon Sep 17 00:00:00 2001 From: "Dr. David von Oheimb" Date: Tue, 12 May 2020 10:14:00 +0200 Subject: [PATCH] Preliminary fix of memory leak in try_decode_PKCS12() - full fix is in #11733 Reviewed-by: Matt Caswell Reviewed-by: David von Oheimb (Merged from https://github.com/openssl/openssl/pull/11470) --- crypto/store/loader_file.c | 1 + 1 file changed, 1 insertion(+) diff --git a/crypto/store/loader_file.c b/crypto/store/loader_file.c index 9f6158ff79..320c527a65 100644 --- a/crypto/store/loader_file.c +++ b/crypto/store/loader_file.c @@ -278,6 +278,7 @@ static OSSL_STORE_INFO *try_decode_PKCS12(const char *pem_name, (void)sk_X509_shift(chain); } } + sk_X509_free(chain); if (!ok) { OSSL_STORE_INFO_free(osi_ca); OSSL_STORE_INFO_free(osi_cert); -- 2.25.1