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
c14a8185
Commit
c14a8185
authored
Mar 07, 2017
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move H2 Rx buf onto srq->ws
parent
b8506b30
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
7 deletions
+9
-7
cache_http2_session.c
bin/varnishd/http2/cache_http2_session.c
+9
-7
No files found.
bin/varnishd/http2/cache_http2_session.c
View file @
c14a8185
...
...
@@ -227,7 +227,7 @@ h2_new_pu_session(struct worker *wrk, const struct h2_sess *h2)
return
(
0
);
}
HTC_RxPipeline
(
h2
->
htc
,
h2
->
htc
->
rxbuf_b
+
sizeof
(
H2_prism
));
HTC_RxInit
(
h2
->
htc
,
wrk
->
a
ws
);
HTC_RxInit
(
h2
->
htc
,
h2
->
ws
);
VSLb
(
h2
->
vsl
,
SLT_Debug
,
"H2: Got pu PRISM"
);
return
(
1
);
...
...
@@ -255,9 +255,9 @@ h2_new_ou_session(struct worker *wrk, struct h2_sess *h2,
req
->
htc
->
pipeline_b
=
NULL
;
req
->
htc
->
pipeline_e
=
NULL
;
/* XXX: This call may assert on buffer overflow if the pipelined
data exceeds the available space in the
a
ws workspace. What to
data exceeds the available space in the ws workspace. What to
do about the overflowing data is an open issue. */
HTC_RxInit
(
h2
->
htc
,
wrk
->
a
ws
);
HTC_RxInit
(
h2
->
htc
,
h2
->
ws
);
/* Start req thread */
(
void
)
h2_new_req
(
wrk
,
h2
,
1
,
req
);
...
...
@@ -280,7 +280,7 @@ h2_new_ou_session(struct worker *wrk, struct h2_sess *h2,
return
(
0
);
}
HTC_RxPipeline
(
h2
->
htc
,
h2
->
htc
->
rxbuf_b
+
sizeof
(
H2_prism
));
HTC_RxInit
(
h2
->
htc
,
wrk
->
a
ws
);
HTC_RxInit
(
h2
->
htc
,
h2
->
ws
);
VSLb
(
h2
->
vsl
,
SLT_Debug
,
"H2: Got PRISM"
);
return
(
1
);
}
...
...
@@ -301,17 +301,18 @@ h2_new_session(struct worker *wrk, void *arg)
assert
(
req
->
transport
==
&
H2_transport
);
wsp
=
WS_Snapshot
(
wrk
->
aws
);
switch
(
req
->
err_code
)
{
case
0
:
/* Direct H2 connection (via Proxy) */
h2
=
h2_new_sess
(
wrk
,
sp
,
req
);
wsp
=
WS_Snapshot
(
h2
->
ws
);
(
void
)
h2_new_req
(
wrk
,
h2
,
0
,
NULL
);
break
;
case
1
:
/* Prior Knowledge H1->H2 upgrade */
h2
=
h2_new_sess
(
wrk
,
sp
,
req
);
wsp
=
WS_Snapshot
(
h2
->
ws
);
(
void
)
h2_new_req
(
wrk
,
h2
,
0
,
NULL
);
if
(
!
h2_new_pu_session
(
wrk
,
h2
))
...
...
@@ -320,6 +321,7 @@ h2_new_session(struct worker *wrk, void *arg)
case
2
:
/* Optimistic H1->H2 upgrade */
h2
=
h2_new_sess
(
wrk
,
sp
,
NULL
);
wsp
=
WS_Snapshot
(
h2
->
ws
);
(
void
)
h2_new_req
(
wrk
,
h2
,
0
,
NULL
);
if
(
!
h2_new_ou_session
(
wrk
,
h2
,
req
))
...
...
@@ -340,8 +342,8 @@ h2_new_session(struct worker *wrk, void *arg)
Lck_Unlock
(
&
h2
->
sess
->
mtx
);
while
(
h2_rxframe
(
wrk
,
h2
))
{
WS_Reset
(
wrk
->
a
ws
,
wsp
);
HTC_RxInit
(
h2
->
htc
,
wrk
->
a
ws
);
WS_Reset
(
h2
->
ws
,
wsp
);
HTC_RxInit
(
h2
->
htc
,
h2
->
ws
);
}
/* Delete all idle streams */
...
...
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