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
d14d97ab
Commit
d14d97ab
authored
Nov 09, 2021
by
Tatsuhiro Tsujikawa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename send_stop_sending to stop_sending
parent
2aed0777
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
16 deletions
+14
-16
src/h2load_http3_session.cc
src/h2load_http3_session.cc
+5
-7
src/h2load_http3_session.h
src/h2load_http3_session.h
+1
-1
src/shrpx_http3_upstream.cc
src/shrpx_http3_upstream.cc
+7
-7
src/shrpx_http3_upstream.h
src/shrpx_http3_upstream.h
+1
-1
No files found.
src/h2load_http3_session.cc
View file @
d14d97ab
...
@@ -213,19 +213,17 @@ void Http3Session::recv_header(int64_t stream_id, const nghttp3_vec *name,
...
@@ -213,19 +213,17 @@ void Http3Session::recv_header(int64_t stream_id, const nghttp3_vec *name,
}
}
namespace
{
namespace
{
int
send_stop_sending
(
nghttp3_conn
*
conn
,
int64_t
stream_id
,
int
stop_sending
(
nghttp3_conn
*
conn
,
int64_t
stream_id
,
uint64_t
app_error_code
,
uint64_t
app_error_code
,
void
*
user_data
,
void
*
user_data
,
void
*
stream_user_data
)
{
void
*
stream_user_data
)
{
auto
s
=
static_cast
<
Http3Session
*>
(
user_data
);
auto
s
=
static_cast
<
Http3Session
*>
(
user_data
);
if
(
s
->
s
end_s
top_sending
(
stream_id
,
app_error_code
)
!=
0
)
{
if
(
s
->
stop_sending
(
stream_id
,
app_error_code
)
!=
0
)
{
return
NGHTTP3_ERR_CALLBACK_FAILURE
;
return
NGHTTP3_ERR_CALLBACK_FAILURE
;
}
}
return
0
;
return
0
;
}
}
}
// namespace
}
// namespace
int
Http3Session
::
send_stop_sending
(
int64_t
stream_id
,
int
Http3Session
::
stop_sending
(
int64_t
stream_id
,
uint64_t
app_error_code
)
{
uint64_t
app_error_code
)
{
auto
rv
=
ngtcp2_conn_shutdown_stream_read
(
client_
->
quic
.
conn
,
stream_id
,
auto
rv
=
ngtcp2_conn_shutdown_stream_read
(
client_
->
quic
.
conn
,
stream_id
,
app_error_code
);
app_error_code
);
if
(
rv
!=
0
)
{
if
(
rv
!=
0
)
{
...
@@ -300,7 +298,7 @@ int Http3Session::init_conn() {
...
@@ -300,7 +298,7 @@ int Http3Session::init_conn() {
nullptr
,
// begin_trailers
nullptr
,
// begin_trailers
h2load
::
recv_header
,
h2load
::
recv_header
,
nullptr
,
// end_trailers
nullptr
,
// end_trailers
h2load
::
s
end_s
top_sending
,
h2load
::
stop_sending
,
};
};
auto
config
=
client_
->
worker
->
config
;
auto
config
=
client_
->
worker
->
config
;
...
...
src/h2load_http3_session.h
View file @
d14d97ab
...
@@ -51,7 +51,7 @@ public:
...
@@ -51,7 +51,7 @@ public:
void
begin_headers
(
int64_t
stream_id
);
void
begin_headers
(
int64_t
stream_id
);
void
recv_header
(
int64_t
stream_id
,
const
nghttp3_vec
*
name
,
void
recv_header
(
int64_t
stream_id
,
const
nghttp3_vec
*
name
,
const
nghttp3_vec
*
value
);
const
nghttp3_vec
*
value
);
int
s
end_s
top_sending
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
stop_sending
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
close_stream
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
close_stream
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
shutdown_stream_read
(
int64_t
stream_id
);
int
shutdown_stream_read
(
int64_t
stream_id
);
...
...
src/shrpx_http3_upstream.cc
View file @
d14d97ab
...
@@ -2353,12 +2353,12 @@ int Http3Upstream::http_stream_close(Downstream *downstream,
...
@@ -2353,12 +2353,12 @@ int Http3Upstream::http_stream_close(Downstream *downstream,
}
}
namespace
{
namespace
{
int
http_s
end_s
top_sending
(
nghttp3_conn
*
conn
,
int64_t
stream_id
,
int
http_stop_sending
(
nghttp3_conn
*
conn
,
int64_t
stream_id
,
uint64_t
app_error_code
,
void
*
user_data
,
uint64_t
app_error_code
,
void
*
user_data
,
void
*
stream_user_data
)
{
void
*
stream_user_data
)
{
auto
upstream
=
static_cast
<
Http3Upstream
*>
(
user_data
);
auto
upstream
=
static_cast
<
Http3Upstream
*>
(
user_data
);
if
(
upstream
->
http_s
end_s
top_sending
(
stream_id
,
app_error_code
)
!=
0
)
{
if
(
upstream
->
http_stop_sending
(
stream_id
,
app_error_code
)
!=
0
)
{
return
NGHTTP3_ERR_CALLBACK_FAILURE
;
return
NGHTTP3_ERR_CALLBACK_FAILURE
;
}
}
...
@@ -2366,8 +2366,8 @@ int http_send_stop_sending(nghttp3_conn *conn, int64_t stream_id,
...
@@ -2366,8 +2366,8 @@ int http_send_stop_sending(nghttp3_conn *conn, int64_t stream_id,
}
}
}
// namespace
}
// namespace
int
Http3Upstream
::
http_s
end_s
top_sending
(
int64_t
stream_id
,
int
Http3Upstream
::
http_stop_sending
(
int64_t
stream_id
,
uint64_t
app_error_code
)
{
uint64_t
app_error_code
)
{
auto
rv
=
ngtcp2_conn_shutdown_stream_read
(
conn_
,
stream_id
,
app_error_code
);
auto
rv
=
ngtcp2_conn_shutdown_stream_read
(
conn_
,
stream_id
,
app_error_code
);
if
(
ngtcp2_err_is_fatal
(
rv
))
{
if
(
ngtcp2_err_is_fatal
(
rv
))
{
ULOG
(
ERROR
,
this
)
<<
"ngtcp2_conn_shutdown_stream_read: "
ULOG
(
ERROR
,
this
)
<<
"ngtcp2_conn_shutdown_stream_read: "
...
@@ -2422,7 +2422,7 @@ int Http3Upstream::setup_httpconn() {
...
@@ -2422,7 +2422,7 @@ int Http3Upstream::setup_httpconn() {
nullptr
,
// begin_trailers
nullptr
,
// begin_trailers
nullptr
,
// recv_trailer
nullptr
,
// recv_trailer
nullptr
,
// end_trailers
nullptr
,
// end_trailers
shrpx
::
http_s
end_s
top_sending
,
shrpx
::
http_stop_sending
,
shrpx
::
http_end_stream
,
shrpx
::
http_end_stream
,
shrpx
::
http_reset_stream
,
shrpx
::
http_reset_stream
,
};
};
...
...
src/shrpx_http3_upstream.h
View file @
d14d97ab
...
@@ -141,7 +141,7 @@ public:
...
@@ -141,7 +141,7 @@ public:
int
http_acked_stream_data
(
Downstream
*
downstream
,
uint64_t
datalen
);
int
http_acked_stream_data
(
Downstream
*
downstream
,
uint64_t
datalen
);
int
http_shutdown_stream_read
(
int64_t
stream_id
);
int
http_shutdown_stream_read
(
int64_t
stream_id
);
int
http_reset_stream
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
http_reset_stream
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
http_s
end_s
top_sending
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
http_stop_sending
(
int64_t
stream_id
,
uint64_t
app_error_code
);
int
http_recv_data
(
Downstream
*
downstream
,
const
uint8_t
*
data
,
int
http_recv_data
(
Downstream
*
downstream
,
const
uint8_t
*
data
,
size_t
datalen
);
size_t
datalen
);
int
handshake_completed
();
int
handshake_completed
();
...
...
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