remove the receive flow control window from the params negotiator

The receive windows are not negotiated, they are just announced to the
peer.
This commit is contained in:
Marten Seemann
2017-10-15 13:50:19 +07:00
parent f5acb690d3
commit 480db80da1
10 changed files with 45 additions and 96 deletions

View File

@@ -37,26 +37,19 @@ func newFlowController(
streamID protocol.StreamID,
contributesToConnection bool,
connParams handshake.ParamsNegotiator,
receiveWindow protocol.ByteCount,
maxReceiveWindow protocol.ByteCount,
rttStats *congestion.RTTStats,
) *flowController {
fc := flowController{
return &flowController{
streamID: streamID,
contributesToConnection: contributesToConnection,
connParams: connParams,
rttStats: rttStats,
receiveWindow: receiveWindow,
receiveWindowIncrement: receiveWindow,
maxReceiveWindowIncrement: maxReceiveWindow,
}
if streamID == 0 {
fc.receiveWindow = connParams.GetReceiveConnectionFlowControlWindow()
fc.receiveWindowIncrement = fc.receiveWindow
} else {
fc.receiveWindow = connParams.GetReceiveStreamFlowControlWindow()
fc.receiveWindowIncrement = fc.receiveWindow
}
return &fc
}
func (c *flowController) ContributesToConnection() bool {