diff options
author | Rich Salz <rsalz@openssl.org> | 2016-11-03 13:16:26 -0400 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2016-11-03 15:25:22 -0400 |
commit | 0d325d9cb9ecb10cb1d41f64751ca8d8f2df472b (patch) | |
tree | a56e416b0b2de4e827d8ef39c4287ccdb8b06d0a | |
parent | 2cf10e88b7221e1edbbdc8ecc89abe2953a668b1 (diff) |
Update CRYPTO_set_mem_debug() doc
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/1842)
(cherry picked from commit 00bb5504cc62693e05ff4e699f379011c55ecc84)
-rw-r--r-- | doc/crypto/OPENSSL_malloc.pod | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/doc/crypto/OPENSSL_malloc.pod b/doc/crypto/OPENSSL_malloc.pod index 50f09751cf..2104f43108 100644 --- a/doc/crypto/OPENSSL_malloc.pod +++ b/doc/crypto/OPENSSL_malloc.pod @@ -135,8 +135,10 @@ at build-time). This adds some overhead by keeping a list of all memory allocations, and removes items from the list when they are free'd. This is most useful for identifying memory leaks. -CRYPTO_set_mem_debug() turns this tracking on and off. It is normally -called at startup, but can be called at any time. +CRYPTO_set_mem_debug() turns this tracking on and off. In order to have +any effect, is must be called before any of the allocation functions +(e.g., CRYPTO_malloc()) are called, and is therefore normally one of the +first lines of main() in an application. CRYPTO_mem_ctrl() provides fine-grained control of memory leak tracking. To enable tracking call CRYPTO_mem_ctrl() with a B<mode> argument of |