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
0290623e
Commit
0290623e
authored
Jan 19, 2016
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reduce strength of arguments from busyobj to boc
parent
3479b0d8
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
14 deletions
+14
-14
cache_esi_deliver.c
bin/varnishd/cache/cache_esi_deliver.c
+7
-7
cache_priv.h
bin/varnishd/cache/cache_priv.h
+1
-1
cache_req_fsm.c
bin/varnishd/cache/cache_req_fsm.c
+4
-4
cache_http1_deliver.c
bin/varnishd/http1/cache_http1_deliver.c
+2
-2
No files found.
bin/varnishd/cache/cache_esi_deliver.c
View file @
0290623e
...
@@ -668,7 +668,7 @@ ved_objiterate(void *priv, int flush, const void *ptr, ssize_t len)
...
@@ -668,7 +668,7 @@ ved_objiterate(void *priv, int flush, const void *ptr, ssize_t len)
}
}
static
void
static
void
ved_stripgzip
(
struct
req
*
req
,
struct
b
usyobj
*
bo
)
ved_stripgzip
(
struct
req
*
req
,
struct
b
oc
*
boc
)
{
{
ssize_t
l
;
ssize_t
l
;
char
*
p
;
char
*
p
;
...
@@ -687,9 +687,9 @@ ved_stripgzip(struct req *req, struct busyobj *bo)
...
@@ -687,9 +687,9 @@ ved_stripgzip(struct req *req, struct busyobj *bo)
foo
.
preq
=
ecx
->
preq
;
foo
.
preq
=
ecx
->
preq
;
memset
(
foo
.
tailbuf
,
0xdd
,
sizeof
foo
.
tailbuf
);
memset
(
foo
.
tailbuf
,
0xdd
,
sizeof
foo
.
tailbuf
);
/*
XXX: Is this really required ?
*/
/*
OA_GZIPBITS is not valid until BOS_FINISHED
*/
if
(
bo
!=
NULL
)
if
(
bo
c
!=
NULL
)
ObjWaitState
(
bo
->
bo
c
,
BOS_FINISHED
);
ObjWaitState
(
boc
,
BOS_FINISHED
);
AN
(
ObjCheckFlag
(
req
->
wrk
,
req
->
objcore
,
OF_GZIPED
));
AN
(
ObjCheckFlag
(
req
->
wrk
,
req
->
objcore
,
OF_GZIPED
));
...
@@ -751,13 +751,13 @@ ved_vdp_bytes(struct req *req, enum vdp_action act, void **priv,
...
@@ -751,13 +751,13 @@ ved_vdp_bytes(struct req *req, enum vdp_action act, void **priv,
/*--------------------------------------------------------------------*/
/*--------------------------------------------------------------------*/
static
void
__match_proto__
(
vtr_deliver_f
)
static
void
__match_proto__
(
vtr_deliver_f
)
VED_Deliver
(
struct
req
*
req
,
struct
b
usyobj
*
bo
,
int
wantbody
)
VED_Deliver
(
struct
req
*
req
,
struct
b
oc
*
boc
,
int
wantbody
)
{
{
int
i
;
int
i
;
struct
ecx
*
ecx
;
struct
ecx
*
ecx
;
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
CHECK_OBJ_ORNULL
(
bo
,
BUSYOBJ
_MAGIC
);
CHECK_OBJ_ORNULL
(
bo
c
,
BOC
_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
->
objcore
,
OBJCORE_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
->
objcore
,
OBJCORE_MAGIC
);
CAST_OBJ_NOTNULL
(
ecx
,
req
->
transport_priv
,
ECX_MAGIC
);
CAST_OBJ_NOTNULL
(
ecx
,
req
->
transport_priv
,
ECX_MAGIC
);
...
@@ -768,7 +768,7 @@ VED_Deliver(struct req *req, struct busyobj *bo, int wantbody)
...
@@ -768,7 +768,7 @@ VED_Deliver(struct req *req, struct busyobj *bo, int wantbody)
req
->
res_mode
|=
RES_ESI_CHILD
;
req
->
res_mode
|=
RES_ESI_CHILD
;
i
=
ObjCheckFlag
(
req
->
wrk
,
req
->
objcore
,
OF_GZIPED
);
i
=
ObjCheckFlag
(
req
->
wrk
,
req
->
objcore
,
OF_GZIPED
);
if
(
ecx
->
isgzip
&&
i
&&
!
(
req
->
res_mode
&
RES_ESI
))
{
if
(
ecx
->
isgzip
&&
i
&&
!
(
req
->
res_mode
&
RES_ESI
))
{
ved_stripgzip
(
req
,
bo
);
ved_stripgzip
(
req
,
bo
c
);
}
else
{
}
else
{
if
(
ecx
->
isgzip
&&
!
i
)
if
(
ecx
->
isgzip
&&
!
i
)
VDP_push
(
req
,
ved_pretend_gzip
,
ecx
,
1
);
VDP_push
(
req
,
ved_pretend_gzip
,
ecx
,
1
);
...
...
bin/varnishd/cache/cache_priv.h
View file @
0290623e
...
@@ -36,7 +36,7 @@
...
@@ -36,7 +36,7 @@
* or may not, be talking a "real" HTTP protocol itself.
* or may not, be talking a "real" HTTP protocol itself.
*/
*/
typedef
void
vtr_deliver_f
(
struct
req
*
,
struct
b
usyobj
*
,
int
sendbody
);
typedef
void
vtr_deliver_f
(
struct
req
*
,
struct
b
oc
*
,
int
sendbody
);
struct
transport
{
struct
transport
{
unsigned
magic
;
unsigned
magic
;
...
...
bin/varnishd/cache/cache_req_fsm.c
View file @
0290623e
...
@@ -48,7 +48,7 @@
...
@@ -48,7 +48,7 @@
#include "vtim.h"
#include "vtim.h"
static
void
static
void
cnt_vdp
(
struct
req
*
req
,
struct
b
usyobj
*
bo
)
cnt_vdp
(
struct
req
*
req
,
struct
b
oc
*
boc
)
{
{
const
char
*
r
;
const
char
*
r
;
uint16_t
status
;
uint16_t
status
;
...
@@ -58,7 +58,7 @@ cnt_vdp(struct req *req, struct busyobj *bo)
...
@@ -58,7 +58,7 @@ cnt_vdp(struct req *req, struct busyobj *bo)
CHECK_OBJ_NOTNULL
(
req
->
transport
,
TRANSPORT_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
->
transport
,
TRANSPORT_MAGIC
);
resp_len
=
http_GetContentLength
(
req
->
resp
);
resp_len
=
http_GetContentLength
(
req
->
resp
);
if
(
bo
!=
NULL
)
if
(
bo
c
!=
NULL
)
req
->
resp_len
=
resp_len
;
req
->
resp_len
=
resp_len
;
else
else
req
->
resp_len
=
ObjGetLen
(
req
->
wrk
,
req
->
objcore
);
req
->
resp_len
=
ObjGetLen
(
req
->
wrk
,
req
->
objcore
);
...
@@ -105,7 +105,7 @@ cnt_vdp(struct req *req, struct busyobj *bo)
...
@@ -105,7 +105,7 @@ cnt_vdp(struct req *req, struct busyobj *bo)
"Content-Length: %jd"
,
req
->
resp_len
);
"Content-Length: %jd"
,
req
->
resp_len
);
}
}
req
->
transport
->
deliver
(
req
,
bo
,
sendbody
);
req
->
transport
->
deliver
(
req
,
bo
c
,
sendbody
);
}
}
/*--------------------------------------------------------------------
/*--------------------------------------------------------------------
...
@@ -207,7 +207,7 @@ cnt_deliver(struct worker *wrk, struct req *req)
...
@@ -207,7 +207,7 @@ cnt_deliver(struct worker *wrk, struct req *req)
}
}
}
}
cnt_vdp
(
req
,
bo
);
cnt_vdp
(
req
,
bo
==
NULL
?
NULL
:
bo
->
boc
);
VSLb_ts_req
(
req
,
"Resp"
,
W_TIM_real
(
wrk
));
VSLb_ts_req
(
req
,
"Resp"
,
W_TIM_real
(
wrk
));
...
...
bin/varnishd/http1/cache_http1_deliver.c
View file @
0290623e
...
@@ -79,12 +79,12 @@ v1d_error(struct req *req, const char *msg)
...
@@ -79,12 +79,12 @@ v1d_error(struct req *req, const char *msg)
*/
*/
void
__match_proto__
(
vtr_deliver_f
)
void
__match_proto__
(
vtr_deliver_f
)
V1D_Deliver
(
struct
req
*
req
,
struct
b
usyobj
*
bo
,
int
sendbody
)
V1D_Deliver
(
struct
req
*
req
,
struct
b
oc
*
boc
,
int
sendbody
)
{
{
int
err
=
0
;
int
err
=
0
;
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
CHECK_OBJ_ORNULL
(
bo
,
BUSYOBJ
_MAGIC
);
CHECK_OBJ_ORNULL
(
bo
c
,
BOC
_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
->
objcore
,
OBJCORE_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
->
objcore
,
OBJCORE_MAGIC
);
if
(
sendbody
)
{
if
(
sendbody
)
{
...
...
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