- updated warnhing message condition to also check LAG time in addition to lag count

This commit is contained in:
Mark Vejvoda
2010-06-30 18:59:28 +00:00
parent a064a4a4c8
commit 217c92e939

View File

@@ -263,8 +263,10 @@ bool ServerInterface::clientLagCheck(ConnectionSlot* connectionSlot) {
}
}
// New lag check warning
else if(maxFrameCountLagAllowed > 0 && warnFrameCountLagPercent > 0 &&
(clientLagCount > (maxFrameCountLagAllowed * warnFrameCountLagPercent))) {
else if((maxFrameCountLagAllowed > 0 && warnFrameCountLagPercent > 0 &&
clientLagCount > (maxFrameCountLagAllowed * warnFrameCountLagPercent)) ||
(maxClientLagTimeAllowed > 0 && warnFrameCountLagPercent > 0 &&
clientLagTime > (maxClientLagTimeAllowed * warnFrameCountLagPercent)) ) {
if(connectionSlot->getLagCountWarning() == false) {
connectionSlot->setLagCountWarning(true);