projects
/
oweals
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1c4f340
)
Ensure OSSL_PARAM_BLD_free() can accept a NULL
author
Matt Caswell
<matt@openssl.org>
Fri, 24 Apr 2020 10:44:15 +0000
(11:44 +0100)
committer
Matt Caswell
<matt@openssl.org>
Mon, 4 May 2020 08:30:55 +0000
(09:30 +0100)
All OpenSSL free functions should accept NULL.
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/11635)
crypto/param_build.c
patch
|
blob
|
history
diff --git
a/crypto/param_build.c
b/crypto/param_build.c
index 43b194bceab53418db6b9406e2c518d28b81b1ec..76522cd3770f26a047815345c6541f4e5f25d398 100644
(file)
--- a/
crypto/param_build.c
+++ b/
crypto/param_build.c
@@
-125,6
+125,8
@@
static void free_all_params(OSSL_PARAM_BLD *bld)
void OSSL_PARAM_BLD_free(OSSL_PARAM_BLD *bld)
{
+ if (bld == NULL)
+ return;
free_all_params(bld);
sk_OSSL_PARAM_BLD_DEF_free(bld->params);
OPENSSL_free(bld);