projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
kdfs: make free calls check for NULL.
[openssl.git]
/
providers
/
implementations
/
kdfs
/
sskdf.c
diff --git
a/providers/implementations/kdfs/sskdf.c
b/providers/implementations/kdfs/sskdf.c
index 4f69eec7f66ef8648e341e459a735e564e6ee6f9..2c4600d2058e0f758a240c40441822028ad4f578 100644
(file)
--- a/
providers/implementations/kdfs/sskdf.c
+++ b/
providers/implementations/kdfs/sskdf.c
@@
-315,8
+315,10
@@
static void sskdf_free(void *vctx)
{
KDF_SSKDF *ctx = (KDF_SSKDF *)vctx;
- sskdf_reset(ctx);
- OPENSSL_free(ctx);
+ if (ctx != NULL) {
+ sskdf_reset(ctx);
+ OPENSSL_free(ctx);
+ }
}
static int sskdf_set_buffer(unsigned char **out, size_t *out_len,