diff mbox series

[1/2] test/crypto: fix unexpected test abort

Message ID 20220926100120.3980185-2-ruifeng.wang@arm.com (mailing list archive)
State Superseded, archived
Delegated to: akhil goyal
Headers show
Series fixes after sym session rework | expand


Context Check Description
ci/iol-testing warning apply patch failure
ci/checkpatch success coding style OK

Commit Message

Ruifeng Wang Sept. 26, 2022, 10:01 a.m. UTC
rte_cryptodev_sym_session_create now updates rte_errno. So rte_errno
should be reset before executing current test case. This prevents
current case from being aborted due to errno set by previous negative

Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
 app/test/test_cryptodev.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series


diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index b77e14cb06..981db009b8 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -2176,6 +2176,7 @@  test_AES_CBC_HMAC_SHA1_encrypt_digest(void)
 	ut_params->auth_xform.auth.key.data = hmac_sha1_key;
 	ut_params->auth_xform.auth.digest_length = DIGEST_BYTE_LENGTH_SHA1;
+	rte_errno = 0;
 	ut_params->sess = rte_cryptodev_sym_session_create(
 			ts_params->valid_devs[0], &ut_params->cipher_xform,