Skip to content

Commit

Permalink
Raise send window timeouts as stream errors
Browse files Browse the repository at this point in the history
  • Loading branch information
mtrudel committed Jun 14, 2024
1 parent 4d63553 commit 3d67aa4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/bandit/http2/stream.ex
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,11 @@ defmodule Bandit.HTTP2.Stream do
|> do_recv_send_window_update(delta)
|> send_data(rest, end_stream)
after
stream.read_timeout -> raise "Timeout waiting for space in the send_window"
stream.read_timeout ->
stream_error!(
"Timeout waiting for space in the send_window",
Bandit.HTTP2.Errors.flow_control_error()
)
end
end
end
Expand Down

0 comments on commit 3d67aa4

Please sign in to comment.