]> git.sesse.net Git - nageru/commitdiff
Remove a dead code line.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Wed, 1 Mar 2017 19:25:17 +0000 (20:25 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Wed, 1 Mar 2017 19:25:17 +0000 (20:25 +0100)
Found by Coverity Scan.

mixer.cpp

index 79d8e97eb9b9391cda7ceaf2ad686719a9f00caf..bf7dfd7523ff87772a3db44d07c4a380a9e482ad 100644 (file)
--- a/mixer.cpp
+++ b/mixer.cpp
@@ -166,17 +166,13 @@ void QueueLengthPolicy::update_policy(unsigned queue_length)
                been_at_safe_point_since_last_starvation = false;
                return;
        }
-       if (queue_length >= 1) {
-               if (queue_length >= safe_queue_length) {
-                       been_at_safe_point_since_last_starvation = true;
-               }
-               if (++frames_with_at_least_one >= 1000 && safe_queue_length > 1) {
-                       --safe_queue_length;
-                       fprintf(stderr, "Card %u: Spare frames for more than 1000 frames, reducing safe limit to %u frame(s)\n",
-                               card_index, safe_queue_length);
-                       frames_with_at_least_one = 0;
-               }
-       } else {
+       if (queue_length >= safe_queue_length) {
+               been_at_safe_point_since_last_starvation = true;
+       }
+       if (++frames_with_at_least_one >= 1000 && safe_queue_length > 1) {
+               --safe_queue_length;
+               fprintf(stderr, "Card %u: Spare frames for more than 1000 frames, reducing safe limit to %u frame(s)\n",
+                       card_index, safe_queue_length);
                frames_with_at_least_one = 0;
        }
 }