Skip to content
Snippets Groups Projects
Commit 628ccc4f authored by David Schleef's avatar David Schleef Committed by Sebastian Dröge
Browse files

mpegtsdemux: check value before using as denominator

parent 95219646
No related branches found
No related tags found
No related merge requests found
......@@ -3655,6 +3655,9 @@ mpegts_packetizer_offset_to_ts (MpegTSPacketizer2 * packetizer, guint64 offset,
pcrtable = get_pcr_table (packetizer, pid);
if (G_UNLIKELY (pcrtable->last_offset <= pcrtable->first_offset))
return GST_CLOCK_TIME_NONE;
/* Convert byte difference into time difference */
res = PCRTIME_TO_GSTTIME (gst_util_uint64_scale (offset - priv->refoffset,
pcrtable->last_pcr - pcrtable->first_pcr,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment