From 4b21581b3686c3d6d30f12c1ecc3885ca4202efb Mon Sep 17 00:00:00 2001 From: Stephen Birarda Date: Tue, 4 Aug 2015 14:32:48 -0700 Subject: [PATCH] fix for min NAK interval in Connection --- libraries/networking/src/udt/Connection.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libraries/networking/src/udt/Connection.cpp b/libraries/networking/src/udt/Connection.cpp index 0817c23e8d..9e5bcc3dde 100644 --- a/libraries/networking/src/udt/Connection.cpp +++ b/libraries/networking/src/udt/Connection.cpp @@ -300,8 +300,6 @@ bool Connection::processReceivedSequenceNumber(SequenceNumber sequenceNumber, in sendNAK(sequenceNumber); // figure out when we should send the next loss report, if we haven't heard anything back - _nakInterval = (_rtt + 4 * _rttVariance); - int receivedPacketsPerSecond = _receiveWindow.getPacketReceiveSpeed(); if (receivedPacketsPerSecond > 0) { @@ -582,7 +580,7 @@ void Connection::updateRTT(int rtt) { } int Connection::estimatedTimeout() const { - return _congestionControl->_userDefinedRto ? _rtt + _rttVariance * 4 : _congestionControl->_rto; + return _congestionControl->_userDefinedRto ? _congestionControl->_rto : _rtt + _rttVariance * 4; } void Connection::updateCongestionControlAndSendQueue(std::function congestionCallback) {