mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-25 17:50:36 +00:00
mpeg4videoparse: minor fix to error handling
We weren't handling unparseable codec_data in some cases. https://bugzilla.gnome.org/show_bug.cgi?id=635202
This commit is contained in:
parent
04eb581480
commit
522f470883
1 changed files with 3 additions and 0 deletions
|
@ -731,6 +731,7 @@ gst_mpeg4vparse_sink_setcaps (GstPad * pad, GstCaps * caps)
|
||||||
} else {
|
} else {
|
||||||
const guint8 *data = GST_BUFFER_DATA (buf);
|
const guint8 *data = GST_BUFFER_DATA (buf);
|
||||||
|
|
||||||
|
res = FALSE;
|
||||||
if (data[0] == 0 && data[1] == 0 && data[2] == 1) {
|
if (data[0] == 0 && data[1] == 0 && data[2] == 1) {
|
||||||
if (data[3] == VOS_STARTCODE) {
|
if (data[3] == VOS_STARTCODE) {
|
||||||
/* Usually the codec data will be a visual object sequence, containing
|
/* Usually the codec data will be a visual object sequence, containing
|
||||||
|
@ -745,6 +746,8 @@ gst_mpeg4vparse_sink_setcaps (GstPad * pad, GstCaps * caps)
|
||||||
res = gst_mpeg4vparse_handle_vo (parse, data, GST_BUFFER_SIZE (buf),
|
res = gst_mpeg4vparse_handle_vo (parse, data, GST_BUFFER_SIZE (buf),
|
||||||
FALSE);
|
FALSE);
|
||||||
}
|
}
|
||||||
|
if (!res)
|
||||||
|
goto failed_parse;
|
||||||
} else {
|
} else {
|
||||||
GST_WARNING_OBJECT (parse,
|
GST_WARNING_OBJECT (parse,
|
||||||
"codec_data does not begin with start code, invalid");
|
"codec_data does not begin with start code, invalid");
|
||||||
|
|
Loading…
Reference in a new issue