From 8ee7c36bb1735a4fb50a9c7a82db8d37cae694c5 Mon Sep 17 00:00:00 2001 From: Daniel Pouzzner Date: Mon, 13 May 2024 19:06:54 -0500 Subject: [PATCH] tests/api.c: add suppression for clang-analyzer-optin.core.EnumCastOutOfRange in "Bad hash type" subtest in test_wc_ecc_sm2_create_digest(). --- tests/api.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/api.c b/tests/api.c index f478538a9b..02f56ebbef 100644 --- a/tests/api.c +++ b/tests/api.c @@ -26100,8 +26100,10 @@ static int test_wc_ecc_sm2_create_digest(void) hashType, hash, sizeof(hash), NULL), BAD_FUNC_ARG); /* Bad hash type. */ + /* // NOLINTBEGIN(clang-analyzer-optin.core.EnumCastOutOfRange) */ ExpectIntEQ(wc_ecc_sm2_create_digest(id, sizeof(id), msg, sizeof(msg), -1, hash, 0, key), BAD_FUNC_ARG); + /* // NOLINTEND(clang-analyzer-optin.core.EnumCastOutOfRange) */ /* Bad hash size. */ ExpectIntEQ(wc_ecc_sm2_create_digest(id, sizeof(id), msg, sizeof(msg), hashType, hash, 0, key), BUFFER_E);