diff options
Diffstat (limited to 'src/lib/libcrypto/ocsp/ocsp_ht.c')
-rw-r--r-- | src/lib/libcrypto/ocsp/ocsp_ht.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lib/libcrypto/ocsp/ocsp_ht.c b/src/lib/libcrypto/ocsp/ocsp_ht.c index 0fa23b027b..db20759d3b 100644 --- a/src/lib/libcrypto/ocsp/ocsp_ht.c +++ b/src/lib/libcrypto/ocsp/ocsp_ht.c | |||
@@ -168,6 +168,7 @@ OCSP_REQ_CTX *OCSP_sendreq_new(BIO *io, char *path, OCSP_REQUEST *req, | |||
168 | rctx->iobuflen = OCSP_MAX_LINE_LEN; | 168 | rctx->iobuflen = OCSP_MAX_LINE_LEN; |
169 | rctx->iobuf = malloc(rctx->iobuflen); | 169 | rctx->iobuf = malloc(rctx->iobuflen); |
170 | if (!rctx->iobuf) { | 170 | if (!rctx->iobuf) { |
171 | BIO_free(rctx->mem); | ||
171 | free(rctx); | 172 | free(rctx); |
172 | return 0; | 173 | return 0; |
173 | } | 174 | } |
@@ -176,12 +177,14 @@ OCSP_REQ_CTX *OCSP_sendreq_new(BIO *io, char *path, OCSP_REQUEST *req, | |||
176 | 177 | ||
177 | if (BIO_printf(rctx->mem, post_hdr, path) <= 0) { | 178 | if (BIO_printf(rctx->mem, post_hdr, path) <= 0) { |
178 | free(rctx->iobuf); | 179 | free(rctx->iobuf); |
180 | BIO_free(rctx->mem); | ||
179 | free(rctx); | 181 | free(rctx); |
180 | return 0; | 182 | return 0; |
181 | } | 183 | } |
182 | 184 | ||
183 | if (req && !OCSP_REQ_CTX_set1_req(rctx, req)) { | 185 | if (req && !OCSP_REQ_CTX_set1_req(rctx, req)) { |
184 | free(rctx->iobuf); | 186 | free(rctx->iobuf); |
187 | BIO_free(rctx->mem); | ||
185 | free(rctx); | 188 | free(rctx); |
186 | return 0; | 189 | return 0; |
187 | } | 190 | } |