Skip to content

Commit

Permalink
Fix incorrect mss calculation when pre-buffer and post-buffer feature…
Browse files Browse the repository at this point in the history
… is used.

(cherry picked from commit ea89245)
  • Loading branch information
yigolden committed Jul 13, 2021
1 parent f5d9bca commit 42ec2ae
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/KcpSharp/KcpConversation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ private KcpConversation(IKcpTransport transport, uint? conversationId, KcpConver
}

_mss = conversationId.HasValue ? _mtu - 24 : _mtu - 20;
_mss = _mss - _preBufferSize - _postBufferSize;

_ssthresh = 2;

Expand Down

0 comments on commit 42ec2ae

Please sign in to comment.