Skip to content

Commit

Permalink
Fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
kar-rahul-aws committed Apr 25, 2024
1 parent eaddb35 commit 98014cf
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,7 @@ void calculateCurrentTime( UTCTime_t * pBaseTime,
/* Slew Adjustment = Slew Rate ( Milliseconds/seconds )
* x
* No. of seconds since last synchronization. */
msElapsedSinceLastSync = msElapsedSinceLastSync + ( uint32_t )( slewRate * ( msElapsedSinceLastSync / 1000 ) );
msElapsedSinceLastSync = msElapsedSinceLastSync + ( uint32_t ) ( slewRate * ( msElapsedSinceLastSync / 1000 ) );
}

/* Set the current UTC time in the output parameter. */
Expand Down Expand Up @@ -977,7 +977,7 @@ static void populateAuthContextForServer( const char * pServer,
for( index = 0; index < strlen( pKeyHexString ); index += 2 )
{
char byteString[ 3 ] = { pKeyHexString[ index ], pKeyHexString[ index + 1 ], '\0' };
uint8_t byteVal = ( uint8_t )( strtoul( byteString, NULL, 16 ) );
uint8_t byteVal = ( uint8_t ) ( strtoul( byteString, NULL, 16 ) );
pAuthContext->pAuthKey[ index / 2 ] = byteVal;
}
}
Expand Down Expand Up @@ -1014,7 +1014,7 @@ static CK_RV setupPkcs11ObjectForAesCmac( const SntpAuthContext_t * pAuthContext
};

/* Update the attributes array with the key of AES-CMAC operation. */
aes_cmac_template[ 6 ].pValue = (uint8_t *)( pAuthContext->pAuthKey );
aes_cmac_template[ 6 ].pValue = (uint8_t *) ( pAuthContext->pAuthKey );
aes_cmac_template[ 6 ].ulValueLen = sizeof( pAuthContext->pAuthKey );

result = xInitializePkcs11Session( pPkcs11Session );
Expand Down Expand Up @@ -1279,7 +1279,7 @@ static uint32_t generateRandomNumber()
if( pkcs11Status == CKR_OK )
{
if( pFunctionList->C_GenerateRandom( session,
( uint8_t * )( &randomNum ),
( uint8_t * ) ( &randomNum ),
sizeof( randomNum ) ) != CKR_OK )
{
LogError( ( "Failed to generate random number. "
Expand Down

0 comments on commit 98014cf

Please sign in to comment.