mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
changed to match type of _mss in compare. also changed float to double for correct return type
This commit is contained in:
parent
ced5f52971
commit
1911301005
1 changed files with 1 additions and 1 deletions
|
@ -29,7 +29,7 @@ void CongestionControl::setMaxBandwidth(int maxBandwidth) {
|
|||
void CongestionControl::setPacketSendPeriod(double newSendPeriod) {
|
||||
Q_ASSERT_X(newSendPeriod >= 0, "CongestionControl::setPacketPeriod", "Can not set a negative packet send period");
|
||||
|
||||
auto packetsPerSecond = _mss > 0.0f ? (double)_maxBandwidth / (BITS_PER_BYTE * _mss) : -1.0f;
|
||||
auto packetsPerSecond = _mss > 0 ? (double)_maxBandwidth / (BITS_PER_BYTE * _mss) : -1.0;
|
||||
if (packetsPerSecond > 0.0) {
|
||||
// anytime the packet send period is about to be increased, make sure it stays below the minimum period,
|
||||
// calculated based on the maximum desired bandwidth
|
||||
|
|
Loading…
Reference in a new issue