mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-26 13:35:42 +01:00
fix style issues with tests/suites/helpers.function
This commit is contained in:
parent
1fef5ff5ec
commit
4291445377
@ -79,8 +79,8 @@ static void hexify(unsigned char *obuf, const unsigned char *ibuf, int len)
|
||||
|
||||
while( len != 0 )
|
||||
{
|
||||
h = (*ibuf) / 16;
|
||||
l = (*ibuf) % 16;
|
||||
h = *ibuf / 16;
|
||||
l = *ibuf % 16;
|
||||
|
||||
if( h < 10 )
|
||||
*obuf++ = '0' + h;
|
||||
@ -107,7 +107,7 @@ static void hexify(unsigned char *obuf, const unsigned char *ibuf, int len)
|
||||
static unsigned char *zero_alloc( size_t len )
|
||||
{
|
||||
void *p;
|
||||
size_t actual_len = len != 0 ? len : 1;
|
||||
size_t actual_len = ( len != 0 ) ? len : 1;
|
||||
|
||||
p = polarssl_malloc( actual_len );
|
||||
assert( p != NULL );
|
||||
@ -269,9 +269,11 @@ static int rnd_pseudo_rand( void *rng_state, unsigned char *output, size_t len )
|
||||
|
||||
for( i = 0; i < 32; i++ )
|
||||
{
|
||||
info->v0 += (((info->v1 << 4) ^ (info->v1 >> 5)) + info->v1) ^ (sum + k[sum & 3]);
|
||||
info->v0 += ( ( ( info->v1 << 4 ) ^ ( info->v1 >> 5 ) )
|
||||
+ info->v1 ) ^ ( sum + k[sum & 3] );
|
||||
sum += delta;
|
||||
info->v1 += (((info->v0 << 4) ^ (info->v0 >> 5)) + info->v0) ^ (sum + k[(sum>>11) & 3]);
|
||||
info->v1 += ( ( ( info->v0 << 4 ) ^ ( info->v0 >> 5 ) )
|
||||
+ info->v0 ) ^ ( sum + k[( sum>>11 ) & 3] );
|
||||
}
|
||||
|
||||
PUT_UINT32_BE( info->v0, result, 0 );
|
||||
|
Loading…
Reference in New Issue
Block a user