mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-17 03:35:21 +00:00
h264parse: Avoid ending up with undefined values
If caps aren't fixed, we'd end up with undefined values for format and align.
This commit is contained in:
parent
64592da3e9
commit
77f254abb3
1 changed files with 4 additions and 4 deletions
|
@ -282,16 +282,16 @@ gst_h264_parse_get_string (GstH264Parse * parse, gboolean format, gint code)
|
|||
static void
|
||||
gst_h264_parse_format_from_caps (GstCaps * caps, guint * format, guint * align)
|
||||
{
|
||||
g_return_if_fail (gst_caps_is_fixed (caps));
|
||||
|
||||
GST_DEBUG ("parsing caps: %" GST_PTR_FORMAT, caps);
|
||||
|
||||
if (format)
|
||||
*format = GST_H264_PARSE_FORMAT_NONE;
|
||||
|
||||
if (align)
|
||||
*align = GST_H264_PARSE_ALIGN_NONE;
|
||||
|
||||
g_return_if_fail (gst_caps_is_fixed (caps));
|
||||
|
||||
GST_DEBUG ("parsing caps: %" GST_PTR_FORMAT, caps);
|
||||
|
||||
if (caps && gst_caps_get_size (caps) > 0) {
|
||||
GstStructure *s = gst_caps_get_structure (caps, 0);
|
||||
const gchar *str = NULL;
|
||||
|
|
Loading…
Reference in a new issue