Remove a memset
Also avoids calling EVP_MD_size() and a missing negative result check. Issue found by Coverity. Reviewed-by: Andy Polyakov <appro@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6592)
This commit is contained in:
parent
bdd92f4d9b
commit
74bfb98037
1 changed files with 0 additions and 2 deletions
|
@ -59,8 +59,6 @@ int sm2_compute_userid_digest(uint8_t *out,
|
|||
goto done;
|
||||
}
|
||||
|
||||
memset(out, 0, EVP_MD_size(digest));
|
||||
|
||||
if (!EVP_DigestInit(hash, digest)) {
|
||||
SM2err(SM2_F_SM2_COMPUTE_USERID_DIGEST, ERR_R_EVP_LIB);
|
||||
goto done;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue