mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-23 12:25:36 +01:00
Adapt mbedtls_ssl_session_copy() to removal of peer_cert
field
This commit is contained in:
parent
94cc26dfa6
commit
6d1986e6f5
@ -286,6 +286,8 @@ int mbedtls_ssl_session_copy( mbedtls_ssl_session *dst,
|
|||||||
memcpy( dst, src, sizeof( mbedtls_ssl_session ) );
|
memcpy( dst, src, sizeof( mbedtls_ssl_session ) );
|
||||||
|
|
||||||
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_KEEP_PEER_CERTIFICATE)
|
||||||
if( src->peer_cert != NULL )
|
if( src->peer_cert != NULL )
|
||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
@ -304,8 +306,7 @@ int mbedtls_ssl_session_copy( mbedtls_ssl_session *dst,
|
|||||||
return( ret );
|
return( ret );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#else /* MBEDTLS_SSL_KEEP_PEER_CERTIFICATE */
|
||||||
#if !defined(MBEDTLS_SSL_KEEP_PEER_CERTIFICATE)
|
|
||||||
if( src->peer_cert_digest != NULL )
|
if( src->peer_cert_digest != NULL )
|
||||||
{
|
{
|
||||||
dst->peer_cert_digest_len = src->peer_cert_digest_len;
|
dst->peer_cert_digest_len = src->peer_cert_digest_len;
|
||||||
|
Loading…
Reference in New Issue
Block a user