mirror of
https://github.com/cuberite/polarssl.git
synced 2025-09-29 08:24:11 -04:00
Fix NULL handling in mbedtls_ssl_config.free() function
Signed-off-by: Troy-Butler <squintik@outlook.com>
This commit is contained in:
parent
9ac3e23f5d
commit
da73abc8d7
@ -6029,6 +6029,10 @@ int mbedtls_ssl_config_defaults(mbedtls_ssl_config *conf,
|
|||||||
*/
|
*/
|
||||||
void mbedtls_ssl_config_free(mbedtls_ssl_config *conf)
|
void mbedtls_ssl_config_free(mbedtls_ssl_config *conf)
|
||||||
{
|
{
|
||||||
|
if (conf == NULL) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
#if defined(MBEDTLS_DHM_C)
|
#if defined(MBEDTLS_DHM_C)
|
||||||
mbedtls_mpi_free(&conf->dhm_P);
|
mbedtls_mpi_free(&conf->dhm_P);
|
||||||
mbedtls_mpi_free(&conf->dhm_G);
|
mbedtls_mpi_free(&conf->dhm_G);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user