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
4b8bf44b
Commit
4b8bf44b
authored
Oct 01, 2014
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move the ->getfd() responsibilities a few microns.
parent
db649fe6
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
7 deletions
+6
-7
cache_backend.c
bin/varnishd/cache/cache_backend.c
+5
-1
cache_dir.c
bin/varnishd/cache/cache_dir.c
+1
-5
cache_pipe.c
bin/varnishd/cache/cache_pipe.c
+0
-1
No files found.
bin/varnishd/cache/cache_backend.c
View file @
4b8bf44b
...
...
@@ -429,6 +429,10 @@ vdi_simple_getfd(const struct director *d, struct busyobj *bo)
FIND_TMO
(
between_bytes_timeout
,
vc
->
between_bytes_timeout
,
bo
,
vs
->
vrt
);
}
if
(
vc
!=
NULL
)
vc
->
vsl
=
bo
->
vsl
;
else
VSLb
(
bo
->
vsl
,
SLT_FetchError
,
"no backend connection"
);
return
(
vc
);
}
...
...
@@ -455,7 +459,7 @@ vdi_simple_gethdrs(const struct director *d, struct worker *wrk,
CHECK_OBJ_NOTNULL
(
wrk
,
WORKER_MAGIC
);
CHECK_OBJ_NOTNULL
(
bo
,
BUSYOBJ_MAGIC
);
bo
->
vbc
=
VDI_GetFd
(
d
,
wrk
,
bo
);
bo
->
vbc
=
vdi_simple_getfd
(
d
,
bo
);
if
(
bo
->
vbc
==
NULL
)
{
VSLb
(
bo
->
vsl
,
SLT_FetchError
,
"no backend connection"
);
return
(
-
1
);
...
...
bin/varnishd/cache/cache_dir.c
View file @
4b8bf44b
...
...
@@ -127,7 +127,6 @@ VDI_Finish(const struct director *d, struct worker *wrk, struct busyobj *bo)
struct
vbc
*
VDI_GetFd
(
const
struct
director
*
d
,
struct
worker
*
wrk
,
struct
busyobj
*
bo
)
{
struct
vbc
*
vc
;
CHECK_OBJ_NOTNULL
(
wrk
,
WORKER_MAGIC
);
CHECK_OBJ_NOTNULL
(
bo
,
BUSYOBJ_MAGIC
);
...
...
@@ -138,10 +137,7 @@ VDI_GetFd(const struct director *d, struct worker *wrk, struct busyobj *bo)
return
(
NULL
);
AN
(
d
->
getfd
);
vc
=
d
->
getfd
(
d
,
bo
);
if
(
vc
!=
NULL
)
vc
->
vsl
=
bo
->
vsl
;
return
(
vc
);
return
(
d
->
getfd
(
d
,
bo
));
}
/* Check health ------------------------------------------------------
...
...
bin/varnishd/cache/cache_pipe.c
View file @
4b8bf44b
...
...
@@ -115,7 +115,6 @@ PipeRequest(struct req *req, struct busyobj *bo)
vc
=
VDI_GetFd
(
bo
->
director_req
,
wrk
,
bo
);
if
(
vc
==
NULL
)
{
VSLb
(
bo
->
vsl
,
SLT_FetchError
,
"no backend connection"
);
pipecharge
(
req
,
&
acct_pipe
,
NULL
);
SES_Close
(
req
->
sp
,
SC_OVERLOAD
);
return
;
...
...
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