diff options
author | Peiwei Hu <jlu.hpw@foxmail.com> | 2022-05-21 16:17:23 +0800 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2022-05-24 08:57:37 +0200 |
commit | d649c51a5388912277dffb56d921eb720db54be1 (patch) | |
tree | f98696e10572ae47f0733c4a73fcbaee39b6c892 /apps | |
parent | 36c269c3023f5eb626ec79777ed8b285ef939be2 (diff) |
Fix check of EVP_CIPHER_CTX_ctrl
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18368)
Diffstat (limited to 'apps')
-rw-r--r-- | apps/speed.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/speed.c b/apps/speed.c index 377686681b..3ecc0e9366 100644 --- a/apps/speed.c +++ b/apps/speed.c @@ -3608,8 +3608,8 @@ static void multiblock_speed(const EVP_CIPHER *evp_cipher, int lengths_single, app_bail_out("failed to set cipher key\n"); OPENSSL_clear_free(key, keylen); - if (!EVP_CIPHER_CTX_ctrl(ctx, EVP_CTRL_AEAD_SET_MAC_KEY, - sizeof(no_key), no_key)) + if (EVP_CIPHER_CTX_ctrl(ctx, EVP_CTRL_AEAD_SET_MAC_KEY, + sizeof(no_key), no_key) <= 0) app_bail_out("failed to set AEAD key\n"); if ((alg_name = EVP_CIPHER_get0_name(evp_cipher)) == NULL) app_bail_out("failed to get cipher name\n"); |