handle the transport parameters in the packet packer

This commit is contained in:
Marten Seemann 2018-09-28 15:07:59 -06:00
parent caf8da9adc
commit 9f5bfbe292
5 changed files with 31 additions and 40 deletions

View file

@ -914,12 +914,7 @@ func (s *session) handleCloseError(closeErr closeError) error {
func (s *session) processTransportParameters(params *handshake.TransportParameters) {
s.peerParams = params
s.streamsMap.UpdateLimits(params)
if params.OmitConnectionID {
s.packer.SetOmitConnectionID()
}
if params.MaxPacketSize != 0 {
s.packer.SetMaxPacketSize(params.MaxPacketSize)
}
s.packer.HandleTransportParameters(params)
s.connFlowController.UpdateSendWindow(params.ConnectionFlowControlWindow)
// the crypto stream is the only open stream at this moment
// so we don't need to update stream flow control windows