On Mon, 21 Oct 2024 11:19:08 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:
>> Please find here a fix that improves flow control in the HTTP/2 >> implementation. >> >> The change makes sure that flow control issues are reported to the server as >> FLOW_CONTROL_ERROR. >> It also clarify how some system properties that allow to initialize flow >> control windows are handled, by documenting the full range of valid values >> (when applicable) and explaining what happens if the property points to a >> value that is out of range. >> >> Bad flow control values in the SETTINGS frame will also cause a >> FLOW_CONTROL_ERROR to be reported. > > Daniel Fuchs has updated the pull request incrementally with one additional > commit since the last revision: > > Apply suggestions from code review > > Co-authored-by: Andrey Turbanov <turban...@gmail.com> src/java.net.http/share/classes/jdk/internal/net/http/WindowUpdateSender.java line 127: > 125: // corrective actions and return true. > 126: private boolean checkWindowSizeExceeded(int len) { > 127: int rcv = Math.addExact(received.get(), len); `Math.addExact` throws an `ArithmeticException` if there is an overflow. I think we should catch it here (and take some action) instead of letting it propagate. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/21567#discussion_r1810806457