mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-26 05:35:38 +01:00
Add missing const for consistency
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
This commit is contained in:
parent
e747843903
commit
f009542747
@ -1091,14 +1091,14 @@ static void mbedtls_ssl_cf_memcpy_if_eq( unsigned char *dst,
|
||||
#pragma warning( disable : 4146 )
|
||||
#endif
|
||||
|
||||
/* diff_msb's most significant bit is bit equal to c1 != c2 */
|
||||
/* diff_msb's most significant bit is equal to c1 != c2 */
|
||||
const size_t diff_msb = ( diff | -diff );
|
||||
|
||||
/* diff1 = c1 != c2 */
|
||||
const size_t diff1 = diff_msb >> ( sizeof( diff_msb ) * 8 - 1 );
|
||||
|
||||
/* mask = c1 != c2 ? 0xff : 0x00 */
|
||||
unsigned char mask = (unsigned char) -diff1;
|
||||
const unsigned char mask = (unsigned char) -diff1;
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#pragma warning( pop )
|
||||
|
Loading…
Reference in New Issue
Block a user