Repository: thrift
Updated Branches:
  refs/heads/master b121a586b -> 27be411ee


THRIFT-2936:Minor memory leak in SSL
Client: cpp
Patch: James King

Thrift clients that use SSL leak 64 bytes in two chunks. This is because the 
list of available compression methods is not freed.

This closes #619


Project: http://git-wip-us.apache.org/repos/asf/thrift/repo
Commit: http://git-wip-us.apache.org/repos/asf/thrift/commit/27be411e
Tree: http://git-wip-us.apache.org/repos/asf/thrift/tree/27be411e
Diff: http://git-wip-us.apache.org/repos/asf/thrift/diff/27be411e

Branch: refs/heads/master
Commit: 27be411ee0eb8799861262275c9745017031c3c4
Parents: b121a58
Author: jfarrell <[email protected]>
Authored: Thu Sep 24 22:25:22 2015 -0400
Committer: jfarrell <[email protected]>
Committed: Thu Sep 24 22:26:37 2015 -0400

----------------------------------------------------------------------
 lib/cpp/src/thrift/transport/TSSLSocket.cpp | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/thrift/blob/27be411e/lib/cpp/src/thrift/transport/TSSLSocket.cpp
----------------------------------------------------------------------
diff --git a/lib/cpp/src/thrift/transport/TSSLSocket.cpp 
b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
index c47995e..98c5326 100644
--- a/lib/cpp/src/thrift/transport/TSSLSocket.cpp
+++ b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
@@ -124,10 +124,9 @@ void cleanupOpenSSL() {
   CRYPTO_set_dynlock_create_callback(NULL);
   CRYPTO_set_dynlock_lock_callback(NULL);
   CRYPTO_set_dynlock_destroy_callback(NULL);
-  sk_SSL_COMP_free(SSL_COMP_get_compression_methods());
-  CRYPTO_cleanup_all_ex_data();
   ERR_free_strings();
   EVP_cleanup();
+  CRYPTO_cleanup_all_ex_data();
   ERR_remove_state(0);
   mutexes.reset();
 }

Reply via email to