mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 08:46:40 +00:00
gst/gstpad.c: Make it actually compile too..
Original commit message from CVS: * gst/gstpad.c: (gst_pad_link_check_compatible_unlocked): Make it actually compile too..
This commit is contained in:
parent
b5b28e2e39
commit
ae957681a7
2 changed files with 20 additions and 13 deletions
|
@ -1,3 +1,8 @@
|
|||
2006-01-20 Wim Taymans <wim@fluendo.com>
|
||||
|
||||
* gst/gstpad.c: (gst_pad_link_check_compatible_unlocked):
|
||||
Make it actually compile too..
|
||||
|
||||
2006-01-20 Wim Taymans <wim@fluendo.com>
|
||||
|
||||
* gst/gstcaps.c:
|
||||
|
|
28
gst/gstpad.c
28
gst/gstpad.c
|
@ -1507,6 +1507,7 @@ gst_pad_link_check_compatible_unlocked (GstPad * src, GstPad * sink)
|
|||
{
|
||||
GstCaps *srccaps;
|
||||
GstCaps *sinkcaps;
|
||||
GstCaps *icaps;
|
||||
|
||||
srccaps = gst_pad_get_caps_unlocked (src);
|
||||
sinkcaps = gst_pad_get_caps_unlocked (sink);
|
||||
|
@ -1516,24 +1517,25 @@ gst_pad_link_check_compatible_unlocked (GstPad * src, GstPad * sink)
|
|||
|
||||
/* if we have caps on both pads we can check the intersection. If one
|
||||
* of the caps is NULL, we return TRUE. */
|
||||
if (srccaps && sinkcaps) {
|
||||
GstCaps *icaps;
|
||||
if (srccaps == NULL || sinkcaps == NULL)
|
||||
goto done;
|
||||
|
||||
icaps = gst_caps_intersect (srccaps, sinkcaps);
|
||||
gst_caps_unref (srccaps);
|
||||
gst_caps_unref (sinkcaps);
|
||||
icaps = gst_caps_intersect (srccaps, sinkcaps);
|
||||
gst_caps_unref (srccaps);
|
||||
gst_caps_unref (sinkcaps);
|
||||
|
||||
if (icaps == NULL)
|
||||
goto was_null;
|
||||
if (icaps == NULL)
|
||||
goto was_null;
|
||||
|
||||
GST_CAT_DEBUG (GST_CAT_CAPS,
|
||||
"intersection caps %p %" GST_PTR_FORMAT, icaps, icaps);
|
||||
GST_CAT_DEBUG (GST_CAT_CAPS,
|
||||
"intersection caps %p %" GST_PTR_FORMAT, icaps, icaps);
|
||||
|
||||
if (gst_caps_is_empty (icaps))
|
||||
goto was_empty;
|
||||
if (gst_caps_is_empty (icaps))
|
||||
goto was_empty;
|
||||
|
||||
gst_caps_unref (icaps);
|
||||
}
|
||||
gst_caps_unref (icaps);
|
||||
|
||||
done:
|
||||
return TRUE;
|
||||
|
||||
/* incompatible cases */
|
||||
|
|
Loading…
Reference in a new issue