From: Jelle van der Waa Date: Tue, 30 May 2017 13:55:05 +0000 (+0200) Subject: openssl_pkcs12_read: add missing BIO_free X-Git-Tag: php-7.2.0alpha1~12^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c742abb3ce3789bd2ff73d7f48bba04a5a2f585e;p=php openssl_pkcs12_read: add missing BIO_free When filling the extracerts array with certificates bio_out is created but not free'd leading to a small memory leak of 224 bytes (reported by valgrind). --- diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index c1aa19679e..77897a2f44 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -2990,6 +2990,7 @@ PHP_FUNCTION(openssl_pkcs12_read) } X509_free(aCA); + BIO_free(bio_out); } sk_X509_free(ca);