mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-02 12:32:29 +00:00
element: don't crash on missing template
Some request pads don't have a padtemplate (mostly those from encodebin). Avoid crashing in this case.
This commit is contained in:
parent
5e4c13fc97
commit
76a60c4c42
1 changed files with 3 additions and 2 deletions
|
@ -316,8 +316,9 @@ gst_element_release_request_pad (GstElement * element, GstPad * pad)
|
|||
|
||||
g_return_if_fail (GST_IS_ELEMENT (element));
|
||||
g_return_if_fail (GST_IS_PAD (pad));
|
||||
g_return_if_fail (GST_PAD_TEMPLATE_PRESENCE (GST_PAD_PAD_TEMPLATE (pad))
|
||||
== GST_PAD_REQUEST);
|
||||
g_return_if_fail (GST_PAD_PAD_TEMPLATE (pad) == NULL ||
|
||||
GST_PAD_TEMPLATE_PRESENCE (GST_PAD_PAD_TEMPLATE (pad)) ==
|
||||
GST_PAD_REQUEST);
|
||||
|
||||
oclass = GST_ELEMENT_GET_CLASS (element);
|
||||
|
||||
|
|
Loading…
Reference in a new issue