Skip to content

Commit

Permalink
Fix code style
Browse files Browse the repository at this point in the history
  • Loading branch information
Christoph M. Wintersteiger authored and yanesca committed Aug 19, 2019
1 parent 09a24b3 commit c25df68
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion library/ecdh.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ int mbedtls_ecdh_can_do( mbedtls_ecp_group_id gid )
{
/* At this time, all groups support ECDH. */
(void) gid;
return 1;
return( 1 );
}

#if !defined(MBEDTLS_ECDH_GEN_PUBLIC_ALT)
Expand Down
4 changes: 2 additions & 2 deletions library/ecdsa.c
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ static int ecdsa_sign_restartable( mbedtls_ecp_group *grp,
mbedtls_mpi *pk = &k, *pr = r;

/* Fail cleanly on curves such as Curve25519 that can't be used for ECDSA */
if( !mbedtls_ecdsa_can_do( grp->id ) || grp->N.p == NULL )
if( ! mbedtls_ecdsa_can_do( grp->id ) || grp->N.p == NULL )
return( MBEDTLS_ERR_ECP_BAD_INPUT_DATA );

/* Make sure d is in range 1..n-1 */
Expand Down Expand Up @@ -516,7 +516,7 @@ static int ecdsa_verify_restartable( mbedtls_ecp_group *grp,
mbedtls_mpi_init( &u1 ); mbedtls_mpi_init( &u2 );

/* Fail cleanly on curves such as Curve25519 that can't be used for ECDSA */
if( !mbedtls_ecdsa_can_do( grp->id ) || grp->N.p == NULL )
if( ! mbedtls_ecdsa_can_do( grp->id ) || grp->N.p == NULL )
return( MBEDTLS_ERR_ECP_BAD_INPUT_DATA );

ECDSA_RS_ENTER( ver );
Expand Down

0 comments on commit c25df68

Please sign in to comment.