forge
Explore
Log in

Don't you dare go Hollow

S4: matroska codec_id matches on media alone; the kind != 0 filter was redundant (kind 0 already maps to no media)

Browse files at this commit

adc0ddfeb4aeb0dba74c78edebcd58272e1c848fAhmet Kaan GümüşParent: ba413cf
crates/ec-matroska/src/demux.rsmodified+1 -1
@@ -1385,7 +1385,7 @@ pub(crate) fn parse_tracks(
1385 // time base and nothing here reintroduces a float clock.1385 // time base and nothing here reintroduces a float clock.
1386 let step = default_duration.map(|ns| (ns / scale_ns.max(1)).max(1) as i64);1386 let step = default_duration.map(|ns| (ns / scale_ns.max(1)).max(1) as i64);
1387 let depth = u32::try_from(bits).unwrap_or(u32::MAX);1387 let depth = u32::try_from(bits).unwrap_or(u32::MAX);
1388- let codec_id = match media.filter(|_| kind != 0) {1388+ let codec_id = match media {
1389 Some(_) => codec_of(&codec, depth)?1389 Some(_) => codec_of(&codec, depth)?
1390 .or_else(|| video_codec_from_private(&codec, private.as_deref())),1390 .or_else(|| video_codec_from_private(&codec, private.as_deref())),
1391 None => None,1391 None => None,