From 9a53a4b9aadb4522d9354d722c3dbdfcb5bbf0bc Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Fri, 31 Aug 2018 09:04:25 -0400 Subject: Fixed two memory leaks in x509 csr extensions (#4434) * Fixed a memory leak in x.509 OCSP no check * Fix the _actual_ leak * Speed up symbolizations * Disable backtrace by default, because it doesn't work on Windows * line length --- src/_cffi_src/openssl/x509.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/_cffi_src') diff --git a/src/_cffi_src/openssl/x509.py b/src/_cffi_src/openssl/x509.py index 59fdbf7e..3f2ac90d 100644 --- a/src/_cffi_src/openssl/x509.py +++ b/src/_cffi_src/openssl/x509.py @@ -76,6 +76,8 @@ static const int XN_FLAG_FN_ALIGN; static const int XN_FLAG_RFC2253; static const int XN_FLAG_ONELINE; static const int XN_FLAG_MULTILINE; + +typedef void (*sk_X509_EXTENSION_freefunc)(X509_EXTENSION *); """ FUNCTIONS = """ @@ -282,6 +284,7 @@ int sk_X509_EXTENSION_push(X509_EXTENSIONS *, X509_EXTENSION *); int sk_X509_EXTENSION_insert(X509_EXTENSIONS *, X509_EXTENSION *, int); X509_EXTENSION *sk_X509_EXTENSION_delete(X509_EXTENSIONS *, int); void sk_X509_EXTENSION_free(X509_EXTENSIONS *); +void sk_X509_EXTENSION_pop_free(X509_EXTENSIONS *, sk_X509_EXTENSION_freefunc); int sk_X509_REVOKED_num(Cryptography_STACK_OF_X509_REVOKED *); X509_REVOKED *sk_X509_REVOKED_value(Cryptography_STACK_OF_X509_REVOKED *, int); -- cgit v1.2.3