mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-27 10:40:34 +00:00
make the registry read the plugin feature's rank - this should even make the autoplugger work again. Did I mention I'...
Original commit message from CVS: make the registry read the plugin feature's rank - this should even make the autoplugger work again. Did I mention I'm annoyed because someone didn't test his rank-removing patch? Once opening gst-player or rhythmbox with it would have shown that it doesn't work anymore...
This commit is contained in:
parent
ebaed96716
commit
5d1e64e379
1 changed files with 17 additions and 1 deletions
|
@ -668,30 +668,46 @@ gst_xml_registry_parse_element_factory (GMarkupParseContext *context, const gcha
|
|||
GstElementFactory *factory = GST_ELEMENT_FACTORY (registry->current_feature);
|
||||
|
||||
if (!strcmp (tag, "name")) {
|
||||
g_free (registry->current_feature->name);
|
||||
registry->current_feature->name = g_strndup (text, text_len);
|
||||
}
|
||||
else if (!strcmp (tag, "longname")) {
|
||||
g_free (factory->details->longname);
|
||||
factory->details->longname = g_strndup (text, text_len);
|
||||
}
|
||||
else if (!strcmp(tag, "class")) {
|
||||
g_free (factory->details->klass);
|
||||
factory->details->klass = g_strndup (text, text_len);
|
||||
}
|
||||
else if (!strcmp(tag, "description")) {
|
||||
g_free (factory->details->description);
|
||||
factory->details->description = g_strndup (text, text_len);
|
||||
}
|
||||
else if (!strcmp(tag, "license")) {
|
||||
g_free (factory->details->license);
|
||||
factory->details->license = g_strndup (text, text_len);
|
||||
}
|
||||
else if (!strcmp(tag, "version")) {
|
||||
g_free (factory->details->version);
|
||||
factory->details->version = g_strndup (text, text_len);
|
||||
}
|
||||
else if (!strcmp(tag, "author")) {
|
||||
g_free (factory->details->author);
|
||||
factory->details->author = g_strndup (text, text_len);
|
||||
}
|
||||
else if (!strcmp(tag, "copyright")) {
|
||||
g_free (factory->details->copyright);
|
||||
factory->details->copyright = g_strndup (text, text_len);
|
||||
}
|
||||
|
||||
else if (!strcmp(tag, "rank")) {
|
||||
gint rank;
|
||||
gchar *ret;
|
||||
rank = strtol (text, &ret, 0);
|
||||
if (ret == text + text_len) {
|
||||
gst_element_factory_set_rank (factory, rank);
|
||||
}
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue