diff options
author | Nicola Murino <nicola.murino@gmail.com> | 2012-01-28 11:13:16 +0100 |
---|---|---|
committer | Vincent Penquerc'h <vincent.penquerch@collabora.co.uk> | 2012-02-06 10:23:51 +0000 |
commit | 32f8a04b5708d92067ffe9e3699cd889b166caf5 (patch) | |
tree | 2242fc543e40ffe4525169aed6d5cb5e166a3501 /gst | |
parent | 4e2cf393c0516dbb2ecaa6b8d9b92eae598a30c4 (diff) |
matroskademux: avoid posting invalid duration for each frame
https://bugzilla.gnome.org/show_bug.cgi?id=666583
Diffstat (limited to 'gst')
-rw-r--r-- | gst/matroska/matroska-demux.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/gst/matroska/matroska-demux.c b/gst/matroska/matroska-demux.c index c30e0d028..6e49baa42 100644 --- a/gst/matroska/matroska-demux.c +++ b/gst/matroska/matroska-demux.c @@ -3512,10 +3512,12 @@ gst_matroska_demux_parse_blockgroup_or_simpleblock (GstMatroskaDemux * demux, gst_segment_set_duration (&demux->common.segment, GST_FORMAT_TIME, last_stop_end - demux->stream_start_time); GST_OBJECT_UNLOCK (demux); - gst_element_post_message (GST_ELEMENT_CAST (demux), - gst_message_new_duration (GST_OBJECT_CAST (demux), - GST_FORMAT_TIME, GST_CLOCK_TIME_NONE)); - demux->invalid_duration = TRUE; + if (!demux->invalid_duration) { + gst_element_post_message (GST_ELEMENT_CAST (demux), + gst_message_new_duration (GST_OBJECT_CAST (demux), + GST_FORMAT_TIME, GST_CLOCK_TIME_NONE)); + demux->invalid_duration = TRUE; + } } else { GST_OBJECT_UNLOCK (demux); } |