[master] ea25150 Correctly initialize esi-included req->http0
Poul-Henning Kamp
phk at FreeBSD.org
Mon Oct 27 12:05:55 CET 2014
commit ea251504784faab57e0d47941317a7a046ed78a3
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date: Mon Oct 27 10:40:53 2014 +0000
Correctly initialize esi-included req->http0
diff --git a/bin/varnishd/cache/cache_esi_deliver.c b/bin/varnishd/cache/cache_esi_deliver.c
index 5d4588d..deca61e 100644
--- a/bin/varnishd/cache/cache_esi_deliver.c
+++ b/bin/varnishd/cache/cache_esi_deliver.c
@@ -92,10 +92,11 @@ ved_include(struct req *preq, const char *src, const char *host)
HTTP_Copy(req->http0, preq->http0);
+ req->http0->ws = req->ws;
+ req->http0->vsl = req->vsl;
+ req->http0->logtag = SLT_ReqMethod;
req->http0->conds = 0;
- HTTP_Setup(req->http, req->ws, req->vsl, SLT_ReqMethod);
-
http_SetH(req->http0, HTTP_HDR_URL, src);
if (host != NULL && *host != '\0') {
http_Unset(req->http0, H_Host);
diff --git a/bin/varnishd/http1/cache_http1_deliver.c b/bin/varnishd/http1/cache_http1_deliver.c
index 9523a2e..65a2bf6 100644
--- a/bin/varnishd/http1/cache_http1_deliver.c
+++ b/bin/varnishd/http1/cache_http1_deliver.c
@@ -356,7 +356,7 @@ V1D_Deliver(struct req *req, struct busyobj *bo)
else if (!req->gzip_resp &&
ObjCheckFlag(req->wrk, req->objcore, OF_GZIPED))
VDP_push(req, VDP_gunzip, NULL);
-
+
if (req->res_mode & RES_ESI)
ESI_Deliver(req);
else
diff --git a/bin/varnishd/http1/cache_http1_line.c b/bin/varnishd/http1/cache_http1_line.c
index 3254691..271a369 100644
--- a/bin/varnishd/http1/cache_http1_line.c
+++ b/bin/varnishd/http1/cache_http1_line.c
@@ -76,7 +76,7 @@ V1L_Reserve(struct worker *wrk, struct ws *ws, int *fd, struct vsl_log *vsl,
CHECK_OBJ_NOTNULL(wrk, WORKER_MAGIC);
AZ(wrk->v1l);
-
+
res = WS_Snapshot(ws);
v1l = WS_Alloc(ws, sizeof *v1l);
AN(v1l);
More information about the varnish-commit
mailing list