mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
ladspa: Only scan LADSPA subdir APPDATA and COMMONPROGRAMFILES
Don't scan the entire APPDATA and COMMONPROGRAMFILES path tree, just the LADSPA sub-directory inside them, if any. https://bugzilla.gnome.org/show_bug.cgi?id=796450
This commit is contained in:
parent
ff736c730d
commit
14ab3972ef
1 changed files with 11 additions and 5 deletions
|
@ -322,7 +322,7 @@ ladspa_plugin_directory_search (GstPlugin * ladspa_plugin, const char *dir_name)
|
||||||
if (g_module_symbol (plugin, "ladspa_descriptor",
|
if (g_module_symbol (plugin, "ladspa_descriptor",
|
||||||
(gpointer *) & descriptor_function)) {
|
(gpointer *) & descriptor_function)) {
|
||||||
/* we've found a ladspa_descriptor function, now introspect it. */
|
/* we've found a ladspa_descriptor function, now introspect it. */
|
||||||
GST_INFO ("describe %s", file_name);
|
GST_INFO ("Found LADSPA descriptor in %s", file_name);
|
||||||
ladspa_describe_plugin (file_name, entry_name, descriptor_function);
|
ladspa_describe_plugin (file_name, entry_name, descriptor_function);
|
||||||
ok = TRUE;
|
ok = TRUE;
|
||||||
} else {
|
} else {
|
||||||
|
@ -363,18 +363,24 @@ ladspa_plugin_path_search (GstPlugin * plugin)
|
||||||
#ifdef G_OS_WIN32
|
#ifdef G_OS_WIN32
|
||||||
path = g_getenv ("APPDATA");
|
path = g_getenv ("APPDATA");
|
||||||
if (path) {
|
if (path) {
|
||||||
|
gchar *path_subdir = g_build_filename (path, "LADSPA", NULL);
|
||||||
if (ladspa_path->len)
|
if (ladspa_path->len)
|
||||||
g_string_append_printf (ladspa_path, G_SEARCHPATH_SEPARATOR_S "%s", path);
|
g_string_append_printf (ladspa_path, G_SEARCHPATH_SEPARATOR_S "%s",
|
||||||
|
path_subdir);
|
||||||
else
|
else
|
||||||
g_string_append (ladspa_path, path);
|
g_string_append (ladspa_path, path_subdir);
|
||||||
|
g_free (path_subdir);
|
||||||
}
|
}
|
||||||
|
|
||||||
path = g_getenv ("COMMONPROGRAMFILES");
|
path = g_getenv ("COMMONPROGRAMFILES");
|
||||||
if (path) {
|
if (path) {
|
||||||
|
gchar *path_subdir = g_build_filename (path, "LADSPA", NULL);
|
||||||
if (ladspa_path->len)
|
if (ladspa_path->len)
|
||||||
g_string_append_printf (ladspa_path, G_SEARCHPATH_SEPARATOR_S "%s", path);
|
g_string_append_printf (ladspa_path, G_SEARCHPATH_SEPARATOR_S "%s",
|
||||||
|
path_subdir);
|
||||||
else
|
else
|
||||||
g_string_append (ladspa_path, path);
|
g_string_append (ladspa_path, path_subdir);
|
||||||
|
g_free (path_subdir);
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
path = g_getenv ("HOME");
|
path = g_getenv ("HOME");
|
||||||
|
|
Loading…
Reference in a new issue