diff options
author | Rich Salz <rsalz@openssl.org> | 2015-04-11 10:22:36 -0400 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2015-04-11 10:22:36 -0400 |
commit | 62adbcee392ba1061bf213174e8c59728e00860e (patch) | |
tree | b0a97dcc7e5d9ff3a60b638e45b254a234b83a41 /doc/ssl | |
parent | e2010b202a52be9120582537845f422a60d5d8c0 (diff) | |
download | openssl-62adbcee392ba1061bf213174e8c59728e00860e.tar.gz |
free NULL cleanup 10
Avoid checking for NULL before calling free functions. This gets
ssl.*free:
ssl_sess_cert_free ssl_free ssl_excert_free ssl_cert_free
SSL_free SSL_SRP_CTX_free SSL_SESSION_free SSL_CTX_free
SSL_CTX_SRP_CTX_free SSL_CONF_CTX_free
Reviewed-by: Kurt Roeckx <kurt@openssl.org>
Diffstat (limited to 'doc/ssl')
-rw-r--r-- | doc/ssl/SSL_CONF_CTX_new.pod | 1 | ||||
-rw-r--r-- | doc/ssl/SSL_CTX_free.pod | 2 | ||||
-rw-r--r-- | doc/ssl/SSL_SESSION_free.pod | 1 | ||||
-rw-r--r-- | doc/ssl/SSL_free.pod | 1 |
4 files changed, 5 insertions, 0 deletions
diff --git a/doc/ssl/SSL_CONF_CTX_new.pod b/doc/ssl/SSL_CONF_CTX_new.pod index a9ccb049f4..79c8c94ee0 100644 --- a/doc/ssl/SSL_CONF_CTX_new.pod +++ b/doc/ssl/SSL_CONF_CTX_new.pod @@ -17,6 +17,7 @@ The function SSL_CONF_CTX_new() allocates and initialises an B<SSL_CONF_CTX> structure for use with the SSL_CONF functions. The function SSL_CONF_CTX_free() frees up the context B<cctx>. +If B<cctx> is NULL nothing is done. =head1 RETURN VALUES diff --git a/doc/ssl/SSL_CTX_free.pod b/doc/ssl/SSL_CTX_free.pod index 51d8676968..f37617dcef 100644 --- a/doc/ssl/SSL_CTX_free.pod +++ b/doc/ssl/SSL_CTX_free.pod @@ -20,6 +20,8 @@ It also calls the free()ing procedures for indirectly affected items, if applicable: the session cache, the list of ciphers, the list of Client CAs, the certificates and keys. +If B<ctx> is NULL nothing is done. + =head1 WARNINGS If a session-remove callback is set (SSL_CTX_sess_set_remove_cb()), this diff --git a/doc/ssl/SSL_SESSION_free.pod b/doc/ssl/SSL_SESSION_free.pod index 110ec73ab6..f30fe13c7d 100644 --- a/doc/ssl/SSL_SESSION_free.pod +++ b/doc/ssl/SSL_SESSION_free.pod @@ -15,6 +15,7 @@ SSL_SESSION_free - free an allocated SSL_SESSION structure SSL_SESSION_free() decrements the reference count of B<session> and removes the B<SSL_SESSION> structure pointed to by B<session> and frees up the allocated memory, if the reference count has reached 0. +If B<session> is NULL nothing is done. =head1 NOTES diff --git a/doc/ssl/SSL_free.pod b/doc/ssl/SSL_free.pod index 13c1abd9ec..e3e6f56dc4 100644 --- a/doc/ssl/SSL_free.pod +++ b/doc/ssl/SSL_free.pod @@ -15,6 +15,7 @@ SSL_free - free an allocated SSL structure SSL_free() decrements the reference count of B<ssl>, and removes the SSL structure pointed to by B<ssl> and frees up the allocated memory if the reference count has reached 0. +If B<ssl> is NULL nothing is done. =head1 NOTES |