Coverity 1507376: Dereference after null check
Reviewed-by: Hugo Landau <hlandau@openssl.org> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/18837)
This commit is contained in:
parent
d50e0934e5
commit
93429fc0ce
@ -109,8 +109,10 @@ static void sa_free_leaf(ossl_uintmax_t n, void *p, void *arg)
|
|||||||
|
|
||||||
void ossl_sa_free(OPENSSL_SA *sa)
|
void ossl_sa_free(OPENSSL_SA *sa)
|
||||||
{
|
{
|
||||||
sa_doall(sa, &sa_free_node, NULL, NULL);
|
if (sa != NULL) {
|
||||||
OPENSSL_free(sa);
|
sa_doall(sa, &sa_free_node, NULL, NULL);
|
||||||
|
OPENSSL_free(sa);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ossl_sa_free_leaves(OPENSSL_SA *sa)
|
void ossl_sa_free_leaves(OPENSSL_SA *sa)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user