mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-18 07:47:17 +00:00
encodebin: guard against pathological NULL dereference
Coverity 1139798
This commit is contained in:
parent
f588d14cdc
commit
1afa3040b8
1 changed files with 2 additions and 0 deletions
|
@ -1061,6 +1061,8 @@ _has_class (GstElement * element, const gchar * classname)
|
|||
|
||||
klass = GST_ELEMENT_GET_CLASS (element);
|
||||
value = gst_element_class_get_metadata (klass, GST_ELEMENT_METADATA_KLASS);
|
||||
if (!value)
|
||||
return FALSE;
|
||||
|
||||
return strstr (value, classname) != NULL;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue