Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
nghttp2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
nghttp2
Commits
7a3c656a
Commit
7a3c656a
authored
May 15, 2016
by
Tatsuhiro Tsujikawa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
nghttpx: Refactor
parent
2a96d433
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
8 deletions
+4
-8
src/shrpx_http_downstream_connection.cc
src/shrpx_http_downstream_connection.cc
+1
-5
src/shrpx_worker_process.cc
src/shrpx_worker_process.cc
+3
-3
No files found.
src/shrpx_http_downstream_connection.cc
View file @
7a3c656a
...
...
@@ -665,7 +665,6 @@ int htp_hdrs_completecb(http_parser *htp) {
}
}
auto
status
=
resp
.
http_status
;
// Ignore the response body. HEAD response may contain
// Content-Length or Transfer-Encoding: chunked. Some server send
// 304 status code with nonzero Content-Length, but without response
...
...
@@ -674,10 +673,7 @@ int htp_hdrs_completecb(http_parser *htp) {
// TODO It seems that the cases other than HEAD are handled by
// http-parser. Need test.
return
req
.
method
==
HTTP_HEAD
||
(
100
<=
status
&&
status
<=
199
)
||
status
==
204
||
status
==
304
?
1
:
0
;
return
!
http2
::
expect_response_body
(
req
.
method
,
resp
.
http_status
);
}
}
// namespace
...
...
src/shrpx_worker_process.cc
View file @
7a3c656a
...
...
@@ -341,13 +341,13 @@ void memcached_get_ticket_key_cb(struct ev_loop *loop, ev_timer *w,
key
.
hmac
=
EVP_sha256
();
key
.
hmac_keylen
=
hmac_keylen
;
std
::
copy_n
(
p
,
key
.
data
.
name
.
size
(),
key
.
data
.
name
.
data
(
));
std
::
copy_n
(
p
,
key
.
data
.
name
.
size
(),
std
::
begin
(
key
.
data
.
name
));
p
+=
key
.
data
.
name
.
size
();
std
::
copy_n
(
p
,
enc_keylen
,
key
.
data
.
enc_key
.
data
(
));
std
::
copy_n
(
p
,
enc_keylen
,
std
::
begin
(
key
.
data
.
enc_key
));
p
+=
enc_keylen
;
std
::
copy_n
(
p
,
hmac_keylen
,
key
.
data
.
hmac_key
.
data
(
));
std
::
copy_n
(
p
,
hmac_keylen
,
std
::
begin
(
key
.
data
.
hmac_key
));
p
+=
hmac_keylen
;
ticket_keys
->
keys
.
push_back
(
std
::
move
(
key
));
...
...
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