mirror of
https://github.com/ARMmbed/mbedtls.git
synced 2025-06-06 06:49:22 +08:00
Fix Windows builds, which were getting "possible loss of data"
"bignum_new.c(61,52): warning C4244: 'function': conversion from 'mbedtls_mpi_uint' to 'unsigned int', possible loss of data" Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
This commit is contained in:
parent
7e655f7b4c
commit
268f96b0ef
@ -49,12 +49,11 @@ void mbedtls_mpi_core_montmul( mbedtls_mpi_uint *X,
|
|||||||
(void) mbedtls_mpi_core_mla( T, n + 2, N, n, u1 );
|
(void) mbedtls_mpi_core_mla( T, n + 2, N, n, u1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
mbedtls_mpi_uint carry, borrow, fixup;
|
mbedtls_mpi_uint carry, borrow;
|
||||||
|
|
||||||
carry = T[n];
|
carry = T[n];
|
||||||
borrow = mbedtls_mpi_core_sub( X, T, N, n );
|
borrow = mbedtls_mpi_core_sub( X, T, N, n );
|
||||||
fixup = carry < borrow;
|
(void) mbedtls_mpi_core_add_if( X, N, n, ( carry < borrow ) );
|
||||||
(void) mbedtls_mpi_core_add_if( X, N, n, fixup );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
mbedtls_mpi_uint mbedtls_mpi_core_mla( mbedtls_mpi_uint *d, size_t d_len,
|
mbedtls_mpi_uint mbedtls_mpi_core_mla( mbedtls_mpi_uint *d, size_t d_len,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user