mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-08-08 17:42:09 +03:00
Merge remote-tracking branch 'upstream/development' into iss309
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
* This MPI implementation is based on:
|
||||
*
|
||||
* http://www.cacr.math.uwaterloo.ca/hac/about/chap14.pdf
|
||||
* http://www.stillhq.com/extracted/gnupg-api/mbedtls_mpi/
|
||||
* http://www.stillhq.com/extracted/gnupg-api/mpi/
|
||||
* http://math.libtomcrypt.com/files/tommath.pdf
|
||||
*/
|
||||
|
||||
|
@@ -5735,11 +5735,7 @@ int mbedtls_ssl_set_hs_psk( mbedtls_ssl_context *ssl,
|
||||
mbedtls_free( ssl->handshake->psk );
|
||||
|
||||
if( ( ssl->handshake->psk = mbedtls_calloc( 1, psk_len ) ) == NULL )
|
||||
{
|
||||
mbedtls_free( ssl->handshake->psk );
|
||||
ssl->handshake->psk = NULL;
|
||||
return( MBEDTLS_ERR_SSL_ALLOC_FAILED );
|
||||
}
|
||||
|
||||
ssl->handshake->psk_len = psk_len;
|
||||
memcpy( ssl->handshake->psk, psk, ssl->handshake->psk_len );
|
||||
|
Reference in New Issue
Block a user