Skip to content

Commit

Permalink
tests/api.c: add suppression for clang-analyzer-optin.core.EnumCastOu…
Browse files Browse the repository at this point in the history
…tOfRange in "Bad hash type" subtest in test_wc_ecc_sm2_create_digest().
  • Loading branch information
douzzer committed May 14, 2024
1 parent 009ea66 commit 8ee7c36
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/api.c
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down

0 comments on commit 8ee7c36

Please sign in to comment.