MINOR: mworker/ocsp: skip ocsp-update proxy init in master

The proxy must be created in mworker mode, but only in the worker, not in
the master. The current code creates the proxy in both processes.

The patch only checks that we are not in the master to start the
ocsp-update pre-check.

No backport needed.
This commit is contained in:
William Lallemand 2024-10-17 12:23:13 +02:00
parent 5184f3fb30
commit 043f11e891

View File

@ -1388,6 +1388,11 @@ static struct task *ssl_ocsp_update_responses(struct task *task, void *context,
*/
static int ssl_ocsp_update_precheck()
{
/* the ocsp-update is not usable in the master process */
if (master)
return ERR_NONE;
/* initialize the OCSP update dedicated httpclient */
httpclient_ocsp_update_px = httpclient_create_proxy("<OCSP-UPDATE>");
if (!httpclient_ocsp_update_px)