1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-29 11:41:15 +03:00

Fix resource leaks

These potential leaks were flagged by the Coverity static analyzer.

Signed-off-by: Leonid Rozenboim <leonid.rozenboim@oracle.com>
This commit is contained in:
Leonid Rozenboim
2022-04-21 13:05:10 -07:00
committed by Andrzej Kurek
parent 4d7af2aee0
commit 116f50cd96
2 changed files with 7 additions and 1 deletions

View File

@ -312,7 +312,11 @@ exit:
#endif
if( session_serialized != NULL )
{
mbedtls_platform_zeroize( session_serialized, session_serialized_len );
mbedtls_free(session_serialized);
session_serialized = NULL;
}
return( ret );
}