diff options
author | Nicolas Dufresne <nicolas.dufresne@collabora.com> | 2017-09-23 15:44:09 -0400 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2017-10-19 15:58:41 +0200 |
commit | 756b2ab9e108d6251582e5bacd1e3232977ec6db (patch) | |
tree | 2ae4cd1b1e14eadf511d660b69cb96b5abfb4919 | |
parent | 83994c427410473815ff894a4b519cc36c24327f (diff) | |
download | gstreamer-plugins-good-756b2ab9e108d6251582e5bacd1e3232977ec6db.tar.gz |
flvdemux: Don't pull passed the EOS
When a truncated FLV is provided and processed in pull mode, we
may endup trying to pull passed EOS, causing a rather confusing
warning as the pull offset is an integer overflow.
https://bugzilla.gnome.org/show_bug.cgi?id=787795
-rw-r--r-- | gst/flv/gstflvdemux.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gst/flv/gstflvdemux.c b/gst/flv/gstflvdemux.c index 4c200e220..edda01d36 100644 --- a/gst/flv/gstflvdemux.c +++ b/gst/flv/gstflvdemux.c @@ -2565,6 +2565,9 @@ gst_flv_demux_get_metadata (GstFlvDemux * demux) gst_buffer_unref (buffer); buffer = NULL; + if (G_UNLIKELY (offset < tag_size)) + goto exit; + offset -= tag_size; if (GST_FLOW_OK != gst_flv_demux_pull_range (demux, demux->sinkpad, offset, 12, &buffer)) |