mirror of
https://github.com/reactos/reactos.git
synced 2025-08-07 05:43:08 +00:00
[MBEDTLS] Update to version 2.7.14. CORE-16787
This commit is contained in:
parent
040546d8ff
commit
1b00a1f50f
8 changed files with 115 additions and 52 deletions
5
dll/3rdparty/mbedtls/bignum.c
vendored
5
dll/3rdparty/mbedtls/bignum.c
vendored
|
@ -153,9 +153,10 @@ int mbedtls_mpi_shrink( mbedtls_mpi *X, size_t nblimbs )
|
|||
mbedtls_mpi_uint *p;
|
||||
size_t i;
|
||||
|
||||
/* Actually resize up in this case */
|
||||
/* Actually resize up if there are currently fewer than nblimbs limbs. */
|
||||
if( X->n <= nblimbs )
|
||||
return( mbedtls_mpi_grow( X, nblimbs ) );
|
||||
/* After this point, then X->n > nblimbs and in particular X->n > 0. */
|
||||
|
||||
for( i = X->n - 1; i > 0; i-- )
|
||||
if( X->p[i] != 0 )
|
||||
|
@ -192,7 +193,7 @@ int mbedtls_mpi_copy( mbedtls_mpi *X, const mbedtls_mpi *Y )
|
|||
if( X == Y )
|
||||
return( 0 );
|
||||
|
||||
if( Y->p == NULL )
|
||||
if( Y->n == 0 )
|
||||
{
|
||||
mbedtls_mpi_free( X );
|
||||
return( 0 );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue