Skip to content

Commit

Permalink
No redundant NULL check on free
Browse files Browse the repository at this point in the history
  • Loading branch information
ColtonWilley committed Dec 10, 2024
1 parent 0c20a20 commit 00386c7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions wolfcrypt/src/wc_pkcs11.c
Original file line number Diff line number Diff line change
Expand Up @@ -4050,9 +4050,7 @@ static int Pkcs11GetCert(Pkcs11Session* session, wc_CryptoInfo* info) {
certData = NULL;

exit:
if (certData != NULL) {
XFREE(certData, info->cert.heap, DYNAMIC_TYPE_CERT);
}
XFREE(certData, info->cert.heap, DYNAMIC_TYPE_CERT);
return ret;
}

Expand Down

0 comments on commit 00386c7

Please sign in to comment.