gst/gstelement.c: Make sure we have a GstRealPad before accessing its structure members.

Original commit message from CVS:
* gst/gstelement.c: (gst_element_clear_pad_caps): Make sure we have
a GstRealPad before accessing its structure members.
This commit is contained in:
David Schleef 2004-02-05 02:30:53 +00:00
parent fcc3fd13ae
commit 0f357a0852
2 changed files with 8 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2004-02-04 David Schleef <ds@schleef.org>
* gst/gstelement.c: (gst_element_clear_pad_caps): Make sure we have
a GstRealPad before accessing its structure members.
2004-02-04 Benjamin Otte <in7y118@public.uni-hamburg.de>
* gst/gstclock.c: (gst_clock_init), (gst_clock_set_speed),

View file

@ -2757,7 +2757,9 @@ gst_element_clear_pad_caps (GstElement *element)
GstPad *pad = GST_PAD (pads->data);
gst_pad_unnegotiate (pad);
gst_caps_replace (&GST_RPAD_EXPLICIT_CAPS (pad), NULL);
if (GST_IS_REAL_PAD (pad)){
gst_caps_replace (&GST_RPAD_EXPLICIT_CAPS (pad), NULL);
}
pads = g_list_next (pads);
}