Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
U
unique-xids
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
uplex-varnish
unique-xids
Commits
99d67512
Commit
99d67512
authored
Jun 19, 2012
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make HTC_Init() part of getting a request
parent
47c7bc11
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
15 deletions
+11
-15
cache.h
bin/varnishd/cache/cache.h
+1
-1
cache_center.c
bin/varnishd/cache/cache_center.c
+3
-13
cache_session.c
bin/varnishd/cache/cache_session.c
+7
-1
No files found.
bin/varnishd/cache/cache.h
View file @
99d67512
...
@@ -921,7 +921,7 @@ struct sesspool *SES_NewPool(struct pool *pp, unsigned pool_no);
...
@@ -921,7 +921,7 @@ struct sesspool *SES_NewPool(struct pool *pp, unsigned pool_no);
void
SES_DeletePool
(
struct
sesspool
*
sp
);
void
SES_DeletePool
(
struct
sesspool
*
sp
);
int
SES_Schedule
(
struct
sess
*
sp
);
int
SES_Schedule
(
struct
sess
*
sp
);
void
SES_Handle
(
struct
sess
*
sp
,
double
now
);
void
SES_Handle
(
struct
sess
*
sp
,
double
now
);
void
SES_GetReq
(
struct
sess
*
sp
);
struct
req
*
SES_GetReq
(
struct
sess
*
sp
);
void
SES_ReleaseReq
(
struct
sess
*
sp
);
void
SES_ReleaseReq
(
struct
sess
*
sp
);
pool_func_t
SES_pool_accept_task
;
pool_func_t
SES_pool_accept_task
;
...
...
bin/varnishd/cache/cache_center.c
View file @
99d67512
...
@@ -110,16 +110,10 @@ cnt_wait(struct sess *sp, struct worker *wrk, struct req *req)
...
@@ -110,16 +110,10 @@ cnt_wait(struct sess *sp, struct worker *wrk, struct req *req)
assert
(
!
isnan
(
sp
->
t_rx
));
assert
(
!
isnan
(
sp
->
t_rx
));
if
(
req
==
NULL
)
{
if
(
req
==
NULL
)
{
SES_GetReq
(
sp
);
req
=
SES_GetReq
(
sp
);
req
=
sp
->
req
;
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
assert
(
req
->
sp
==
sp
);
HTC_Init
(
req
->
htc
,
req
->
ws
,
sp
->
fd
,
sp
->
req
->
vsl
,
cache_param
->
http_req_size
,
cache_param
->
http_req_hdr_len
);
}
else
{
assert
(
req
->
sp
==
sp
);
}
}
assert
(
req
->
sp
==
sp
);
AZ
(
req
->
vcl
);
AZ
(
req
->
vcl
);
AZ
(
req
->
obj
);
AZ
(
req
->
obj
);
...
@@ -945,13 +939,9 @@ cnt_first(struct sess *sp, struct worker *wrk)
...
@@ -945,13 +939,9 @@ cnt_first(struct sess *sp, struct worker *wrk)
/* Allocate a request already now, so we can VSL to it */
/* Allocate a request already now, so we can VSL to it */
AZ
(
sp
->
req
);
AZ
(
sp
->
req
);
SES_GetReq
(
sp
);
req
=
SES_GetReq
(
sp
);
req
=
sp
->
req
;
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
CHECK_OBJ_NOTNULL
(
req
,
REQ_MAGIC
);
assert
(
req
->
sp
==
sp
);
assert
(
req
->
sp
==
sp
);
HTC_Init
(
req
->
htc
,
req
->
ws
,
sp
->
fd
,
req
->
vsl
,
cache_param
->
http_req_size
,
cache_param
->
http_req_hdr_len
);
VTCP_name
(
&
sp
->
sockaddr
,
sp
->
sockaddrlen
,
VTCP_name
(
&
sp
->
sockaddr
,
sp
->
sockaddrlen
,
sp
->
addr
,
sizeof
sp
->
addr
,
sp
->
port
,
sizeof
sp
->
port
);
sp
->
addr
,
sizeof
sp
->
addr
,
sp
->
port
,
sizeof
sp
->
port
);
...
...
bin/varnishd/cache/cache_session.c
View file @
99d67512
...
@@ -287,7 +287,7 @@ SES_Delete(struct sess *sp, const char *reason, double now)
...
@@ -287,7 +287,7 @@ SES_Delete(struct sess *sp, const char *reason, double now)
* Alloc/Free sp->req
* Alloc/Free sp->req
*/
*/
void
struct
req
*
SES_GetReq
(
struct
sess
*
sp
)
SES_GetReq
(
struct
sess
*
sp
)
{
{
struct
sesspool
*
pp
;
struct
sesspool
*
pp
;
...
@@ -341,6 +341,12 @@ SES_GetReq(struct sess *sp)
...
@@ -341,6 +341,12 @@ SES_GetReq(struct sess *sp)
assert
(
p
<
e
);
assert
(
p
<
e
);
WS_Init
(
req
->
ws
,
"req"
,
p
,
e
-
p
);
WS_Init
(
req
->
ws
,
"req"
,
p
,
e
-
p
);
HTC_Init
(
req
->
htc
,
req
->
ws
,
sp
->
fd
,
req
->
vsl
,
cache_param
->
http_req_size
,
cache_param
->
http_req_hdr_len
);
return
(
req
);
}
}
void
void
...
...
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