The branch master has been updated via f297e4ecc3e5bd9f460ffc99f38680e34d6d4d2f (commit) from 23be743286c0f0a160de33365ef34af39427eac9 (commit)
- Log ----------------------------------------------------------------- commit f297e4ecc3e5bd9f460ffc99f38680e34d6d4d2f Author: Rich Salz <rs...@openssl.org> Date: Thu Mar 15 10:51:17 2018 -0400 Add code to run test, get malloc counts Reviewed-by: Richard Levitte <levi...@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4528) ----------------------------------------------------------------------- Summary of changes: test/sslapitest.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/test/sslapitest.c b/test/sslapitest.c index 2c122be..8e91151 100644 --- a/test/sslapitest.c +++ b/test/sslapitest.c @@ -17,6 +17,7 @@ #include "ssltestlib.h" #include "testutil.h" +#include "testutil/output.h" #include "internal/nelem.h" #include "../ssl/ssl_locl.h" @@ -3638,6 +3639,22 @@ int setup_tests(void) || !TEST_ptr(privkey = test_get_argument(1))) return 0; + if (getenv("OPENSSL_TEST_GETCOUNTS") != NULL) { +#ifdef OPENSSL_NO_CRYPTO_MDEBUG + TEST_error("not supported in this build"); + return 0; +#else + int i, mcount, rcount, fcount; + + for (i = 0; i < 4; i++) + test_export_key_mat(i); + CRYPTO_get_alloc_counts(&mcount, &rcount, &fcount); + test_printf_stdout("malloc %d realloc %d free %d\n", + mcount, rcount, fcount); + return 1; +#endif + } + ADD_TEST(test_large_message_tls); ADD_TEST(test_large_message_tls_read_ahead); #ifndef OPENSSL_NO_DTLS _____ openssl-commits mailing list To unsubscribe: https://mta.openssl.org/mailman/listinfo/openssl-commits