diff options
author | Alex Gaynor <alex.gaynor@gmail.com> | 2018-06-20 08:50:33 -0700 |
---|---|---|
committer | Paul Kehrer <paul.l.kehrer@gmail.com> | 2018-06-20 10:50:33 -0500 |
commit | 58fd9c412ad8e91f1453f86ba1fc16479f5b11d0 (patch) | |
tree | ccde66f0d6a14a9e12190d58b78f7382f1089b1c /tests/hazmat/backends | |
parent | 2d0afd3485a6349924f921d12dc94a302999ae20 (diff) | |
download | cryptography-58fd9c412ad8e91f1453f86ba1fc16479f5b11d0.tar.gz cryptography-58fd9c412ad8e91f1453f86ba1fc16479f5b11d0.tar.bz2 cryptography-58fd9c412ad8e91f1453f86ba1fc16479f5b11d0.zip |
Perform an OPENSSL_cleanup before checking the heap in our memleak tests (#4293)
* Perform an OPENSSL_cleanup before checking the heap in our memleak tests
* Make this binding conditional
* typo
* need to put this call before we reset the function ptrs
Diffstat (limited to 'tests/hazmat/backends')
-rw-r--r-- | tests/hazmat/backends/test_openssl_memleak.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/hazmat/backends/test_openssl_memleak.py b/tests/hazmat/backends/test_openssl_memleak.py index 74973fe5..cd453541 100644 --- a/tests/hazmat/backends/test_openssl_memleak.py +++ b/tests/hazmat/backends/test_openssl_memleak.py @@ -60,6 +60,9 @@ def main(argv): gc.collect() gc.collect() + if lib.Cryptography_HAS_OPENSSL_CLEANUP: + lib.OPENSSL_cleanup() + # Swap back to the original functions so that if OpenSSL tries to free # something from its atexit handle it won't be going through a Python # function, which will be deallocated when this function returns |