]> git.nihav.org Git - nihav-player.git/commitdiff
ignore underruns when decoding has ended
authorKostya Shishkov <kostya.shishkov@gmail.com>
Mon, 14 Mar 2022 16:54:38 +0000 (17:54 +0100)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Mon, 14 Mar 2022 16:54:38 +0000 (17:54 +0100)
sndplay/src/main.rs

index ce9b6f66d54271788ed7ee2ae21eb30becdba166..c368651a6815e68e3e87e8370d9972eabdc4c3c1 100644 (file)
@@ -363,7 +363,7 @@ impl Player {
                 }
             }
             std::io::stdout().flush().unwrap();
-            if device.size() < underfill_limit && !self.paused && refill_limit < (1 << 20) {
+            if device.size() < underfill_limit && !self.paused && (refill_limit < (1 << 20)) & !eof {
                 if full_ms > 5000 {
                     println!("underrun!");
                 }