Make whitespace consistent
diff --git a/library/psa_crypto_storage.c b/library/psa_crypto_storage.c
index d07bdc5..97b2481 100644
--- a/library/psa_crypto_storage.c
+++ b/library/psa_crypto_storage.c
@@ -227,7 +227,7 @@
* 32-bit integer manipulation macros (little endian)
*/
#ifndef GET_UINT32_LE
-#define GET_UINT32_LE(n,b,i) \
+#define GET_UINT32_LE( n, b, i ) \
{ \
(n) = ( (uint32_t) (b)[(i) ] ) \
| ( (uint32_t) (b)[(i) + 1] << 8 ) \
@@ -237,7 +237,7 @@
#endif
#ifndef PUT_UINT32_LE
-#define PUT_UINT32_LE(n,b,i) \
+#define PUT_UINT32_LE( n, b, i ) \
{ \
(b)[(i) ] = (unsigned char) ( ( (n) ) & 0xFF ); \
(b)[(i) + 1] = (unsigned char) ( ( (n) >> 8 ) & 0xFF ); \
@@ -271,12 +271,12 @@
(psa_persistent_key_storage_format *) storage_data;
memcpy( storage_format->magic, PSA_KEY_STORAGE_MAGIC_HEADER, PSA_KEY_STORAGE_MAGIC_HEADER_LENGTH );
- PUT_UINT32_LE(0, storage_format->version, 0);
- PUT_UINT32_LE(type, storage_format->type, 0);
- PUT_UINT32_LE(policy->usage, storage_format->policy, 0);
- PUT_UINT32_LE(policy->alg, storage_format->policy, sizeof( uint32_t ));
- PUT_UINT32_LE(policy->alg2, storage_format->policy, 2 * sizeof( uint32_t ) );
- PUT_UINT32_LE(data_length, storage_format->data_len, 0);
+ PUT_UINT32_LE( 0, storage_format->version, 0 );
+ PUT_UINT32_LE( type, storage_format->type, 0 );
+ PUT_UINT32_LE( policy->usage, storage_format->policy, 0 );
+ PUT_UINT32_LE( policy->alg, storage_format->policy, sizeof( uint32_t ) );
+ PUT_UINT32_LE( policy->alg2, storage_format->policy, 2 * sizeof( uint32_t ) );
+ PUT_UINT32_LE( data_length, storage_format->data_len, 0 );
memcpy( storage_format->key_data, data, data_length );
}
@@ -307,11 +307,11 @@
if( status != PSA_SUCCESS )
return( status );
- GET_UINT32_LE(version, storage_format->version, 0);
+ GET_UINT32_LE( version, storage_format->version, 0 );
if( version != 0 )
return( PSA_ERROR_STORAGE_FAILURE );
- GET_UINT32_LE(*key_data_length, storage_format->data_len, 0);
+ GET_UINT32_LE( *key_data_length, storage_format->data_len, 0 );
if( *key_data_length > ( storage_data_length - sizeof(*storage_format) ) ||
*key_data_length > PSA_CRYPTO_MAX_STORAGE_SIZE )
return( PSA_ERROR_STORAGE_FAILURE );
@@ -328,10 +328,10 @@
memcpy( *key_data, storage_format->key_data, *key_data_length );
}
- GET_UINT32_LE(*type, storage_format->type, 0);
- GET_UINT32_LE(policy->usage, storage_format->policy, 0);
- GET_UINT32_LE(policy->alg, storage_format->policy, sizeof( uint32_t ));
- GET_UINT32_LE(policy->alg2, storage_format->policy, 2 * sizeof( uint32_t ));
+ GET_UINT32_LE( *type, storage_format->type, 0 );
+ GET_UINT32_LE( policy->usage, storage_format->policy, 0 );
+ GET_UINT32_LE( policy->alg, storage_format->policy, sizeof( uint32_t ) );
+ GET_UINT32_LE( policy->alg2, storage_format->policy, 2 * sizeof( uint32_t ) );
return( PSA_SUCCESS );
}