summaryrefslogtreecommitdiff
path: root/gst
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2017-07-11 20:54:25 +0300
committerSebastian Dröge <sebastian@centricular.com>2017-07-11 20:57:24 +0300
commit16fc8541b56223483e37097c865ef086c27d581c (patch)
tree37a7d2c634ca7f36b71f72dcce2b2fd6aaf06d6f /gst
parent3a1912f88c70877c71426170f5f7919c34b18c4c (diff)
downloadgstreamer-plugins-bad-16fc8541b56223483e37097c865ef086c27d581c.tar.gz
mxfdemux: Create index table arrays with a big enough size
Diffstat (limited to 'gst')
-rw-r--r--gst/mxf/mxfdemux.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gst/mxf/mxfdemux.c b/gst/mxf/mxfdemux.c
index f2a6f93fc..39f34d002 100644
--- a/gst/mxf/mxfdemux.c
+++ b/gst/mxf/mxfdemux.c
@@ -1804,7 +1804,7 @@ gst_mxf_demux_handle_generic_container_essence_element (GstMXFDemux * demux,
index.dts = dts;
index.keyframe = keyframe;
if (etrack->offsets->len < etrack->position)
- g_array_set_size (etrack->offsets, etrack->position);
+ g_array_set_size (etrack->offsets, etrack->position + 1);
g_array_insert_val (etrack->offsets, etrack->position, index);
}
}
@@ -3667,7 +3667,7 @@ collect_index_table_segments (GstMXFDemux * demux)
pts_i = start + i + temporal_offset;
if (t->offsets->len < pts_i)
- g_array_set_size (t->offsets, pts_i);
+ g_array_set_size (t->offsets, pts_i + 1);
index = &g_array_index (t->offsets, GstMXFDemuxIndex, pts_i);
if (!index->initialized) {