armovie: zero-terminated string is not exactly an error
authorKostya Shishkov <kostya.shishkov@gmail.com>
Sun, 5 May 2024 16:46:37 +0000 (18:46 +0200)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Sun, 5 May 2024 16:46:37 +0000 (18:46 +0200)
nihav-acorn/src/demuxers/armovie.rs

index b2bf68467b27e993f17fe0c39ba62ed208992ea0..95c8dad8aa66ff98b18f08d1ef38289a1cd9960b 100644 (file)
@@ -26,7 +26,7 @@ impl<'a> ReadString for ByteReader<'a> {
         let mut res = Vec::new();
         loop {
             let c = self.read_byte()?;
-            if c == b'\n' {
+            if c == b'\n' || c == 0 {
                 break;
             }
             res.push(c);