Allow adding a typefinder without a typefind function so that it can be used

to map the caps to the extension. See #566661.
This commit is contained in:
Wim Taymans 2009-01-21 12:45:45 +01:00 committed by Wim Taymans
parent 1c7ab4ed4f
commit 809372066a
2 changed files with 2 additions and 4 deletions

View file

@ -78,7 +78,6 @@ gst_type_find_register (GstPlugin * plugin, const gchar * name, guint rank,
GstTypeFindFactory *factory;
g_return_val_if_fail (name != NULL, FALSE);
g_return_val_if_fail (func != NULL, FALSE);
GST_INFO ("registering typefind function for %s", name);

View file

@ -238,9 +238,8 @@ gst_type_find_factory_call_function (GstTypeFindFactory * factory,
GST_TYPE_FIND_FACTORY (gst_plugin_feature_load (GST_PLUGIN_FEATURE
(factory)));
if (new_factory) {
g_assert (new_factory->function != NULL);
new_factory->function (find, new_factory->user_data);
if (new_factory->function)
new_factory->function (find, new_factory->user_data);
gst_object_unref (new_factory);
}
}