Improve coding style

Co-authored-by: Tom Cosgrove <81633263+tom-cosgrove-arm@users.noreply.github.com>
Co-authored-by: Werner Lewis <werner.wmlewis@gmail.com>

Signed-off-by: Janos Follath <janos.follath@arm.com>
This commit is contained in:
Janos Follath 2022-08-19 12:05:28 +01:00
parent b7a88eca42
commit ca5688e10c
3 changed files with 9 additions and 6 deletions

View File

@ -174,7 +174,10 @@ int mbedtls_mpi_core_read_le( mbedtls_mpi_uint *X,
memset( X, 0, X_limbs * ciL ); memset( X, 0, X_limbs * ciL );
for( size_t i = 0; i < input_length; i++ ) for( size_t i = 0; i < input_length; i++ )
X[i / ciL] |= ((mbedtls_mpi_uint) input[i]) << ((i % ciL) << 3); {
size_t offset = ( ( i % ciL ) << 3 );
X[i / ciL] |= ( (mbedtls_mpi_uint) input[i] ) << offset;
}
} }
return( 0 ); return( 0 );