mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-28 00:21:48 +03:00
- Allow R and A to point to same mpi in mpi_div_mpi
This commit is contained in:
@ -1195,9 +1195,9 @@ int mpi_div_mpi( mpi *Q, mpi *R, const mpi *A, const mpi *B )
|
||||
if( R != NULL )
|
||||
{
|
||||
mpi_shift_r( &X, k );
|
||||
X.s = A->s;
|
||||
mpi_copy( R, &X );
|
||||
|
||||
R->s = A->s;
|
||||
if( mpi_cmp_int( R, 0 ) == 0 )
|
||||
R->s = 1;
|
||||
}
|
||||
|
Reference in New Issue
Block a user