[master] 2d4c2a50e turn return(vcl(...)) ito a noop for req.restarts > 0
Nils Goroll
nils.goroll at uplex.de
Mon Dec 2 13:18:06 UTC 2019
commit 2d4c2a50e835a3d2d1b1e2cfb1a89bc1b0602c62
Author: Nils Goroll <nils.goroll at uplex.de>
Date: Wed Nov 13 09:57:32 2019 +0100
turn return(vcl(...)) ito a noop for req.restarts > 0
As the FSM will fail for this case, we should not run the code in the
first place.
diff --git a/bin/varnishd/cache/cache_vpi.c b/bin/varnishd/cache/cache_vpi.c
index 1ffc62a3e..2e37e3875 100644
--- a/bin/varnishd/cache/cache_vpi.c
+++ b/bin/varnishd/cache/cache_vpi.c
@@ -93,7 +93,7 @@ VPI_vcl_select(VRT_CTX, VCL_VCL vcl)
CHECK_OBJ_NOTNULL(req, REQ_MAGIC);
CHECK_OBJ_NOTNULL(req->top, REQTOP_MAGIC);
- if (IS_TOPREQ(req) && req->top->vcl0 != NULL)
+ if ((IS_TOPREQ(req) && req->top->vcl0 != NULL) || req->restarts > 0)
return; // Illegal, req-FSM will fail this later.
/* XXX VCL_Task* are somewhat duplicated to those in Req_Rollback called
More information about the varnish-commit
mailing list