mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-08-01 19:54:40 +02:00
OCSP Free
Free the OCSP request when creating the response only if there is an error making the request.
This commit is contained in:
@@ -14048,8 +14048,10 @@ int CreateOcspResponse(WOLFSSL* ssl, OcspRequest** ocspRequest,
|
|||||||
der->length);
|
der->length);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (request != NULL)
|
if (request != NULL && ret != 0) {
|
||||||
XFREE(request, ssl->heap, DYNAMIC_TYPE_OCSP_REQUEST);
|
XFREE(request, ssl->heap, DYNAMIC_TYPE_OCSP_REQUEST);
|
||||||
|
request = NULL;
|
||||||
|
}
|
||||||
#ifdef WOLFSSL_SMALL_STACK
|
#ifdef WOLFSSL_SMALL_STACK
|
||||||
XFREE(cert, ssl->heap, DYNAMIC_TYPE_DCERT);
|
XFREE(cert, ssl->heap, DYNAMIC_TYPE_DCERT);
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user