mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-30 11:08:34 +00:00
mxfdemux: Fix segments iteration
`i >= 0` is always true since it's an unsigned integer ... Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8229>
This commit is contained in:
parent
37a8d49eaa
commit
45df33196f
1 changed files with 3 additions and 3 deletions
|
@ -2497,11 +2497,11 @@ find_entry_for_offset (GstMXFDemux * demux, GstMXFDemuxEssenceTrack * etrack,
|
|||
|
||||
/* Find the segment that covers the given stream offset (the highest one that
|
||||
* covers that offset) */
|
||||
for (i = index_table->segments->len - 1; i >= 0; i--) {
|
||||
for (i = index_table->segments->len; i > 0; i--) {
|
||||
index_segment =
|
||||
&g_array_index (index_table->segments, MXFIndexTableSegment, i);
|
||||
&g_array_index (index_table->segments, MXFIndexTableSegment, i - 1);
|
||||
GST_DEBUG_OBJECT (demux,
|
||||
"Checking segment #%d (essence_offset %" G_GUINT64_FORMAT ")", i,
|
||||
"Checking segment #%d (essence_offset %" G_GUINT64_FORMAT ")", i - 1,
|
||||
index_segment->segment_start_offset);
|
||||
/* Not in the right segment yet */
|
||||
if (offset >= index_segment->segment_start_offset) {
|
||||
|
|
Loading…
Reference in a new issue