From d16df8f60ae22e05084b6a8a154352ba5cc8d573 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= Date: Tue, 31 Mar 2015 14:04:51 +0200 Subject: [PATCH] Cleanup unused bit in ssl Became unused when removing deprecated ssl_set_own_cert_xxx() functions --- include/mbedtls/ssl.h | 1 - library/ssl_tls.c | 7 ------- 2 files changed, 8 deletions(-) diff --git a/include/mbedtls/ssl.h b/include/mbedtls/ssl.h index abe004cc1..fa20c7f42 100644 --- a/include/mbedtls/ssl.h +++ b/include/mbedtls/ssl.h @@ -769,7 +769,6 @@ struct _ssl_key_cert { x509_crt *cert; /*!< cert */ pk_context *key; /*!< private key */ - int key_own_alloc; /*!< did we allocate key? */ ssl_key_cert *next; /*!< next key/cert pair */ }; #endif /* POLARSSL_X509_CRT_PARSE_C */ diff --git a/library/ssl_tls.c b/library/ssl_tls.c index e87731535..fb943dc50 100644 --- a/library/ssl_tls.c +++ b/library/ssl_tls.c @@ -6507,14 +6507,7 @@ static void ssl_key_cert_free( ssl_key_cert *key_cert ) while( cur != NULL ) { next = cur->next; - - if( cur->key_own_alloc ) - { - pk_free( cur->key ); - polarssl_free( cur->key ); - } polarssl_free( cur ); - cur = next; } }