Commit 4feb6c39 authored by Wim Taymans's avatar Wim Taymans
Browse files

caps: fix some 0.11 FIXMEs

parent 67931bfd
......@@ -1047,18 +1047,12 @@ gst_caps_is_subset_structure (const GstCaps * caps,
gboolean
gst_caps_is_equal (const GstCaps * caps1, const GstCaps * caps2)
{
/* FIXME 0.11: NULL pointers are no valid Caps but indicate an error
* So there should be an assertion that caps1 and caps2 != NULL */
g_return_val_if_fail (GST_IS_CAPS (caps1), FALSE);
g_return_val_if_fail (GST_IS_CAPS (caps2), FALSE);
/* NULL <-> NULL is allowed here */
if (G_UNLIKELY (caps1 == caps2))
return TRUE;
/* one of them NULL => they are different (can't be both NULL because
* we checked that above) */
if (G_UNLIKELY (caps1 == NULL || caps2 == NULL))
return FALSE;
if (G_UNLIKELY (gst_caps_is_fixed (caps1) && gst_caps_is_fixed (caps2)))
return gst_caps_is_equal_fixed (caps1, caps2);
......@@ -1082,18 +1076,13 @@ gboolean
gst_caps_is_strictly_equal (const GstCaps * caps1, const GstCaps * caps2)
{
int i;
/* FIXME 0.11: NULL pointers are no valid Caps but indicate an error
* So there should be an assertion that caps1 and caps2 != NULL */
/* NULL <-> NULL is allowed here */
g_return_val_if_fail (GST_IS_CAPS (caps1), FALSE);
g_return_val_if_fail (GST_IS_CAPS (caps2), FALSE);
if (G_UNLIKELY (caps1 == caps2))
return TRUE;
/* one of them NULL => they are different (can't be both NULL because
* we checked that above) */
if (G_UNLIKELY (caps1 == NULL || caps2 == NULL))
return FALSE;
if (GST_CAPS_LEN (caps1) != GST_CAPS_LEN (caps2))
return FALSE;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment