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
cd5857e2
Commit
cd5857e2
authored
Jun 25, 2013
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish
parent
5b6c26c9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
30 deletions
+29
-30
cache_fetch.c
bin/varnishd/cache/cache_fetch.c
+29
-30
No files found.
bin/varnishd/cache/cache_fetch.c
View file @
cd5857e2
...
...
@@ -95,10 +95,9 @@ vbf_stp_mkbereq(struct worker *wrk, struct busyobj *bo, const struct req *req)
http_PrintfHeader
(
bo
->
bereq
,
"X-Varnish: %u"
,
bo
->
vsl
->
wid
&
VSL_IDENTMASK
);
/* XXX: Missing ABANDON */
if
(
wrk
->
handling
==
VCL_RET_ABANDON
)
{
if
(
wrk
->
handling
==
VCL_RET_ABANDON
)
return
(
F_STP_ABANDON
);
}
assert
(
wrk
->
handling
==
VCL_RET_FETCH
);
return
(
F_STP_FETCHHDR
);
}
...
...
@@ -182,6 +181,31 @@ vbf_stp_fetchhdr(struct worker *wrk, struct busyobj *bo, struct req ***reqpp)
VCL_backend_response_method
(
bo
->
vcl
,
wrk
,
NULL
,
bo
,
bo
->
beresp
->
ws
);
bo
->
do_pass
|=
i
;
if
(
wrk
->
handling
==
VCL_RET_DELIVER
)
return
(
F_STP_FETCH
);
return
(
F_STP_NOTYET
);
}
/*--------------------------------------------------------------------
*/
static
enum
fetch_step
vbf_stp_fetch
(
struct
worker
*
wrk
,
struct
busyobj
*
bo
)
{
struct
http
*
hp
,
*
hp2
;
char
*
b
;
uint16_t
nhttp
;
unsigned
l
;
struct
vsb
*
vary
=
NULL
;
int
varyl
=
0
;
struct
object
*
obj
;
CHECK_OBJ_NOTNULL
(
wrk
,
WORKER_MAGIC
);
CHECK_OBJ_NOTNULL
(
bo
,
BUSYOBJ_MAGIC
);
assert
(
wrk
->
handling
==
VCL_RET_DELIVER
);
if
(
bo
->
do_pass
)
bo
->
fetch_objcore
->
flags
|=
OC_F_PASS
;
...
...
@@ -239,31 +263,6 @@ vbf_stp_fetchhdr(struct worker *wrk, struct busyobj *bo, struct req ***reqpp)
else
if
(
bo
->
is_gzip
)
bo
->
vfp
=
&
vfp_testgzip
;
if
(
wrk
->
handling
==
VCL_RET_DELIVER
)
return
(
F_STP_FETCH
);
return
(
F_STP_NOTYET
);
}
/*--------------------------------------------------------------------
*/
static
enum
fetch_step
vbf_stp_fetch
(
struct
worker
*
wrk
,
struct
busyobj
*
bo
)
{
struct
http
*
hp
,
*
hp2
;
char
*
b
;
uint16_t
nhttp
;
unsigned
l
;
struct
vsb
*
vary
=
NULL
;
int
varyl
=
0
;
struct
object
*
obj
;
CHECK_OBJ_NOTNULL
(
wrk
,
WORKER_MAGIC
);
CHECK_OBJ_NOTNULL
(
bo
,
BUSYOBJ_MAGIC
);
assert
(
wrk
->
handling
==
VCL_RET_DELIVER
);
#if 0
if (wrk->handling != VCL_RET_DELIVER)
...
...
@@ -449,7 +448,7 @@ static enum fetch_step
vbf_stp_notyet
(
void
)
{
WRONG
(
"Patience, grashopper, patience..."
);
NEEDLESS_RETURN
(
0
);
NEEDLESS_RETURN
(
F_STP_NOTYET
);
}
/*--------------------------------------------------------------------
...
...
@@ -459,7 +458,7 @@ static enum fetch_step
vbf_stp_done
(
void
)
{
WRONG
(
"Just plain wrong"
);
NEEDLESS_RETURN
(
0
);
NEEDLESS_RETURN
(
F_STP_NOTYET
);
}
/*--------------------------------------------------------------------
...
...
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