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
dc3ca53a
Commit
dc3ca53a
authored
Mar 17, 2021
by
Tatsuhiro Tsujikawa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adopt ngtcp2_crypto_recv_crypto_data_cb
parent
44869a49
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
23 deletions
+1
-23
src/h2load.h
src/h2load.h
+0
-2
src/h2load_quic.cc
src/h2load_quic.cc
+1
-21
No files found.
src/h2load.h
View file @
dc3ca53a
...
...
@@ -466,8 +466,6 @@ struct Client {
size_t
datalen
,
size_t
gso_size
);
void
quic_close_connection
();
int
quic_recv_crypto_data
(
ngtcp2_crypto_level
crypto_level
,
const
uint8_t
*
data
,
size_t
datalen
);
int
quic_handshake_completed
();
int
quic_recv_stream_data
(
uint32_t
flags
,
int64_t
stream_id
,
const
uint8_t
*
data
,
size_t
datalen
);
...
...
src/h2load_quic.cc
View file @
dc3ca53a
...
...
@@ -40,26 +40,6 @@ namespace {
auto
randgen
=
util
::
make_mt19937
();
}
// namespace
namespace
{
int
recv_crypto_data
(
ngtcp2_conn
*
conn
,
ngtcp2_crypto_level
crypto_level
,
uint64_t
offset
,
const
uint8_t
*
data
,
size_t
datalen
,
void
*
user_data
)
{
auto
c
=
static_cast
<
Client
*>
(
user_data
);
if
(
c
->
quic_recv_crypto_data
(
crypto_level
,
data
,
datalen
)
!=
0
)
{
return
NGTCP2_ERR_CRYPTO
;
}
return
0
;
}
}
// namespace
int
Client
::
quic_recv_crypto_data
(
ngtcp2_crypto_level
crypto_level
,
const
uint8_t
*
data
,
size_t
datalen
)
{
return
ngtcp2_crypto_read_write_crypto_data
(
quic
.
conn
,
crypto_level
,
data
,
datalen
);
}
namespace
{
int
handshake_completed
(
ngtcp2_conn
*
conn
,
void
*
user_data
)
{
auto
c
=
static_cast
<
Client
*>
(
user_data
);
...
...
@@ -324,7 +304,7 @@ int Client::quic_init(const sockaddr *local_addr, socklen_t local_addrlen,
auto
callbacks
=
ngtcp2_callbacks
{
ngtcp2_crypto_client_initial_cb
,
nullptr
,
// recv_client_initial
h2load
::
recv_crypto_data
,
ngtcp2_crypto_recv_crypto_data_cb
,
h2load
::
handshake_completed
,
nullptr
,
// recv_version_negotiation
ngtcp2_crypto_encrypt_cb
,
...
...
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