From 92cacec5c34b728c4ae86845e9a1e8948f2c347d Mon Sep 17 00:00:00 2001 From: Stefan Holmer Date: Tue, 10 Oct 2017 09:07:25 +0200 Subject: [PATCH] Fix mistake in range validation of WebRTC-BweBackOffFactor. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bug: webrtc:8212 Change-Id: I89f236099736d2706b25ccc955789449c8e34853 Reviewed-on: https://webrtc-review.googlesource.com/7860 Reviewed-by: Björn Terelius Commit-Queue: Stefan Holmer Cr-Commit-Position: refs/heads/master@{#20215} --- modules/remote_bitrate_estimator/aimd_rate_control.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/remote_bitrate_estimator/aimd_rate_control.cc b/modules/remote_bitrate_estimator/aimd_rate_control.cc index 37c25290bd..25d756c2d6 100644 --- a/modules/remote_bitrate_estimator/aimd_rate_control.cc +++ b/modules/remote_bitrate_estimator/aimd_rate_control.cc @@ -40,9 +40,9 @@ float ReadTrendlineFilterWindowSize() { int parsed_values = sscanf(experiment_string.c_str(), "Enabled-%f", &backoff_factor); if (parsed_values == 1) { - if (backoff_factor < 1.0f) { + if (backoff_factor >= 1.0f) { LOG(WARNING) << "Back-off factor must be less than 1."; - } else if (backoff_factor > 0.0f) { + } else if (backoff_factor <= 0.0f) { LOG(WARNING) << "Back-off factor must be greater than 0."; } else { return backoff_factor;