Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
dc6f44ce
Commit
dc6f44ce
authored
Oct 26, 2020
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Finally, make VDP_Close() take vdp_ctx instead of req arg.
parent
ff82e01a
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
7 additions
and
9 deletions
+7
-9
cache_deliver_proc.c
bin/varnishd/cache/cache_deliver_proc.c
+3
-5
cache_esi_deliver.c
bin/varnishd/cache/cache_esi_deliver.c
+1
-1
cache_filter.h
bin/varnishd/cache/cache_filter.h
+1
-1
cache_http1_deliver.c
bin/varnishd/http1/cache_http1_deliver.c
+1
-1
cache_http2_deliver.c
bin/varnishd/http2/cache_http2_deliver.c
+1
-1
No files found.
bin/varnishd/cache/cache_deliver_proc.c
View file @
dc6f44ce
...
...
@@ -149,18 +149,16 @@ VDP_Push(struct vdp_ctx *vdc, struct ws *ws, const struct vdp *vdp, void *priv)
}
uint64_t
VDP_Close
(
struct
req
*
req
)
VDP_Close
(
struct
vdp_ctx
*
vdc
)
{
struct
vdp_entry
*
vdpe
;
struct
vdp_ctx
*
vdc
;
uint64_t
rv
=
0
;
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
vdc
=
req
->
vdc
;
CHECK_OBJ_NOTNULL
(
vdc
,
VDP_CTX_MAGIC
);
while
(
!
VTAILQ_EMPTY
(
&
vdc
->
vdp
))
{
vdpe
=
VTAILQ_FIRST
(
&
vdc
->
vdp
);
rv
=
vdpe
->
bytes_in
;
VSLb
(
req
->
vsl
,
SLT_VdpAcct
,
"%s %ju %ju"
,
vdpe
->
vdp
->
name
,
VSLb
(
vdc
->
vsl
,
SLT_VdpAcct
,
"%s %ju %ju"
,
vdpe
->
vdp
->
name
,
(
uintmax_t
)
vdpe
->
calls
,
(
uintmax_t
)
rv
);
if
(
vdc
->
retval
>=
0
)
AN
(
vdpe
);
...
...
bin/varnishd/cache/cache_esi_deliver.c
View file @
dc6f44ce
...
...
@@ -880,5 +880,5 @@ ved_deliver(struct req *req, struct boc *boc, int wantbody)
if
(
i
&&
req
->
doclose
==
SC_NULL
)
req
->
doclose
=
SC_REM_CLOSE
;
req
->
acct
.
resp_bodybytes
+=
VDP_Close
(
req
);
req
->
acct
.
resp_bodybytes
+=
VDP_Close
(
req
->
vdc
);
}
bin/varnishd/cache/cache_filter.h
View file @
dc6f44ce
...
...
@@ -155,7 +155,7 @@ extern const struct vdp VDP_range;
void
VDP_Init
(
struct
vdp_ctx
*
vdx
,
struct
worker
*
wrk
,
struct
vsl_log
*
vsl
,
struct
req
*
req
);
uint64_t
VDP_Close
(
struct
req
*
req
);
uint64_t
VDP_Close
(
struct
vdp_ctx
*
);
int
VDP_DeliverObj
(
struct
vdp_ctx
*
vdc
,
struct
objcore
*
oc
);
int
VDP_bytes
(
struct
vdp_ctx
*
,
enum
vdp_action
act
,
const
void
*
ptr
,
ssize_t
len
);
...
...
bin/varnishd/http1/cache_http1_deliver.c
View file @
dc6f44ce
...
...
@@ -158,7 +158,7 @@ V1D_Deliver(struct req *req, struct boc *boc, int sendbody)
AZ
(
req
->
wrk
->
v1l
);
req
->
acct
.
resp_hdrbytes
+=
hdrbytes
;
req
->
acct
.
resp_bodybytes
+=
VDP_Close
(
req
);
req
->
acct
.
resp_bodybytes
+=
VDP_Close
(
req
->
vdc
);
if
(
sc
==
SC_NULL
&&
err
&&
req
->
sp
->
fd
>=
0
)
sc
=
SC_REM_CLOSE
;
...
...
bin/varnishd/http2/cache_http2_deliver.c
View file @
dc6f44ce
...
...
@@ -339,5 +339,5 @@ h2_deliver(struct req *req, struct boc *boc, int sendbody)
}
AZ
(
req
->
wrk
->
v1l
);
req
->
acct
.
resp_bodybytes
+=
VDP_Close
(
req
);
req
->
acct
.
resp_bodybytes
+=
VDP_Close
(
req
->
vdc
);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment