From 2d8fdecdd94791a9d434c1dd9146c916c6893625 Mon Sep 17 00:00:00 2001 From: MORI Shingo Date: Tue, 13 Apr 2021 11:08:32 +0900 Subject: [PATCH] =?UTF-8?q?HTTP2=E3=81=AEOutputStream=E3=81=8Cflush?= =?UTF-8?q?=E3=81=95=E3=82=8C=E3=81=A6=E3=81=AA=E3=81=8B=E3=81=A3=E3=81=9F?= =?UTF-8?q?=E3=81=AE=E3=82=92=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/core/packetproxy/http2/FlowControlManager.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/core/packetproxy/http2/FlowControlManager.java b/src/main/java/core/packetproxy/http2/FlowControlManager.java index 931368e..3564be5 100644 --- a/src/main/java/core/packetproxy/http2/FlowControlManager.java +++ b/src/main/java/core/packetproxy/http2/FlowControlManager.java @@ -100,12 +100,14 @@ public void write(Frame frame) throws Exception { if (frame.getType() == Frame.Type.HEADERS) { /* TODO: maximum concurrent streams is not implemented yet */ outputForFlowControl.write(frame.toByteArray()); + outputForFlowControl.flush(); } else if (frame.getType() == Frame.Type.DATA) { FlowControl flow = getFlow(frame.getStreamId()); flow.enqueue(frame); writeData(flow); } else { outputForFlowControl.write(frame.toByteArray()); + outputForFlowControl.flush(); } }