Some applications are requesting the same pad name multiple times
and the behaviour is undefined and different from element to element
but we don't want to break applications that work just fine.
In 0.11 this check should be an assertion again, although elements
have to do manual checking if the pad already exists again because
it can't be done in a threadsafe way here.
}
pad = gst_element_get_static_pad (element, name);
- if (pad)
+ if (pad) {
gst_object_unref (pad);
- g_return_val_if_fail (pad == NULL, NULL);
+ /* FIXME 0.11: Change this to g_return_val_if_fail() */
+ g_critical ("Element %s already has a pad named %s, the behaviour of "
+ " gst_element_get_request_pad() for existing pads is undefined!",
+ GST_ELEMENT_NAME (element), name);
+ }
}
#endif