diff options
author | Thibault Saunier <tsaunier@gnome.org> | 2014-07-29 16:12:26 +0200 |
---|---|---|
committer | Thibault Saunier <tsaunier@gnome.org> | 2014-09-24 19:21:18 +0200 |
commit | 4c63326a7aa14cbb5958cece2dd2ed4a33e0f9b6 (patch) | |
tree | 991f00eacb740d95c93bd9afe1477eedd09464a1 | |
parent | 22c7559152f77c62e12f80bb33be5429144d46ad (diff) | |
download | gstreamer-plugins-bad-4c63326a7aa14cbb5958cece2dd2ed4a33e0f9b6.tar.gz |
h264parse: Return flushing if we get chained while being set to READY
Or not negotiated in the case we would be actually not negotiated
Currently we are getting assertions from
gst_pb_utils_add_codec_description_to_tag_list because of NULL
caps.
https://bugzilla.gnome.org/show_bug.cgi?id=737186
-rw-r--r-- | gst/videoparsers/gsth264parse.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gst/videoparsers/gsth264parse.c b/gst/videoparsers/gsth264parse.c index 360fc5b21..89b33d569 100644 --- a/gst/videoparsers/gsth264parse.c +++ b/gst/videoparsers/gsth264parse.c @@ -1680,6 +1680,15 @@ gst_h264_parse_pre_push_frame (GstBaseParse * parse, GstBaseParseFrame * frame) /* codec tag */ caps = gst_pad_get_current_caps (GST_BASE_PARSE_SRC_PAD (parse)); + if (caps == NULL) { + if (GST_PAD_IS_FLUSHING (GST_BASE_PARSE_SRC_PAD (h264parse))) { + GST_INFO_OBJECT (h264parse, "Src pad is flushing"); + return GST_FLOW_FLUSHING; + } else { + GST_INFO_OBJECT (h264parse, "Src pad is not negotiated!"); + return GST_FLOW_NOT_NEGOTIATED; + } + } gst_pb_utils_add_codec_description_to_tag_list (taglist, GST_TAG_VIDEO_CODEC, caps); gst_caps_unref (caps); |