mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2025-09-02 17:53:48 +00:00
cdg: typefind: Division by zero fix
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2137>
This commit is contained in:
parent
47ea36be9d
commit
5edcad3734
1 changed files with 1 additions and 1 deletions
|
@ -34,7 +34,7 @@ fn cdg_packets_ratio(typefind: &mut TypeFind, start: i64, len: i64) -> i64 {
|
|||
None => break,
|
||||
}
|
||||
}
|
||||
(count * 100) / total
|
||||
if total == 0 { 0 } else { (count * 100) / total }
|
||||
}
|
||||
|
||||
/* Some CDG files starts drawing right away and then pause for a while
|
||||
|
|
Loading…
Reference in a new issue