From: Shane Lontis Date: Mon, 6 Jul 2020 04:08:58 +0000 (+1000) Subject: Fix CID #1465216 Resource leak in property_fetch X-Git-Tag: openssl-3.0.0-alpha5~57 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=84ba665d72906c36b158071035896f50a9aad808;p=thirdparty%2Fopenssl.git Fix CID #1465216 Resource leak in property_fetch Reviewed-by: Dmitry Belyavskiy (Merged from https://github.com/openssl/openssl/pull/12379) --- diff --git a/crypto/property/property.c b/crypto/property/property.c index a3b52ee44d5..645e361b0a3 100644 --- a/crypto/property/property.c +++ b/crypto/property/property.c @@ -358,9 +358,9 @@ int ossl_method_store_fetch(OSSL_METHOD_STORE *store, int nid, pq = *plp; } else { p2 = ossl_property_merge(pq, *plp); + ossl_property_free(pq); if (p2 == NULL) goto fin; - ossl_property_free(pq); pq = p2; } }