Minor improvements

This commit is contained in:
Hanno Becker 2018-12-12 14:00:26 +00:00
parent ae2ff02ff1
commit e463c42902
2 changed files with 8 additions and 7 deletions

View file

@ -179,9 +179,7 @@ int mbedtls_chachapoly_update_aad( mbedtls_chachapoly_context *ctx,
CHACHAPOLY_VALIDATE_RET( aad_len == 0 || aad != NULL );
if( ctx->state != CHACHAPOLY_STATE_AAD )
{
return( MBEDTLS_ERR_CHACHAPOLY_BAD_STATE );
}
ctx->aad_len += aad_len;