Skip to content

Commit

Permalink
Revert "Revert "[chttp2] fix stream leak with queued flow control upd…
Browse files Browse the repository at this point in the history
…ate and absence of writes (grpc#30907)" (grpc#30991)"

This reverts commit 0f2a0f5.
  • Loading branch information
apolcyn committed Sep 14, 2022
1 parent 16107cf commit 75f4b0e
Show file tree
Hide file tree
Showing 6 changed files with 391 additions and 1 deletion.
36 changes: 36 additions & 0 deletions CMakeLists.txt

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions build_autogenerated.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -2314,7 +2314,7 @@ void grpc_chttp2_act_on_flowctl_action(
grpc_chttp2_transport* t, grpc_chttp2_stream* s) {
WithUrgency(t, action.send_stream_update(),
GRPC_CHTTP2_INITIATE_WRITE_STREAM_FLOW_CONTROL, [t, s]() {
if (s->id != 0) {
if (s->id != 0 && !s->read_closed) {
grpc_chttp2_mark_stream_writable(t, s);
}
});
Expand Down
14 changes: 14 additions & 0 deletions test/core/transport/chttp2/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -313,3 +313,17 @@ grpc_cc_test(
"//test/core/util:grpc_test_util",
],
)

grpc_cc_test(
name = "stream_leak_with_queued_flow_control_update_test",
srcs = ["stream_leak_with_queued_flow_control_update_test.cc"],
external_deps = [
"gtest",
],
language = "C++",
deps = [
"//:gpr",
"//:grpc",
"//test/core/util:grpc_test_util",
],
)

0 comments on commit 75f4b0e

Please sign in to comment.