summaryrefslogtreecommitdiffstats
path: root/crypto/openssl/crypto/ocsp/ocsp_lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/openssl/crypto/ocsp/ocsp_lib.c')
-rw-r--r--crypto/openssl/crypto/ocsp/ocsp_lib.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/crypto/openssl/crypto/ocsp/ocsp_lib.c b/crypto/openssl/crypto/ocsp/ocsp_lib.c
index cabf539..ff781e5 100644
--- a/crypto/openssl/crypto/ocsp/ocsp_lib.c
+++ b/crypto/openssl/crypto/ocsp/ocsp_lib.c
@@ -271,12 +271,18 @@ int OCSP_parse_url(const char *url, char **phost, char **pport, char **ppath,
err:
if (buf)
OPENSSL_free(buf);
- if (*ppath)
+ if (*ppath) {
OPENSSL_free(*ppath);
- if (*pport)
+ *ppath = NULL;
+ }
+ if (*pport) {
OPENSSL_free(*pport);
- if (*phost)
+ *pport = NULL;
+ }
+ if (*phost) {
OPENSSL_free(*phost);
+ *phost = NULL;
+ }
return 0;
}
OpenPOWER on IntegriCloud