Commit 91079ddc authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

plugins must match "lib*_plugin"LIBEXT, not just "*"LIBEXT

parent 6862cff0
...@@ -898,10 +898,11 @@ static void AllocatePluginDir( vlc_object_t *p_this, module_bank_t *p_bank, ...@@ -898,10 +898,11 @@ static void AllocatePluginDir( vlc_object_t *p_this, module_bank_t *p_bank,
AllocatePluginDir (p_this, p_bank, path, i_maxdepth - 1); AllocatePluginDir (p_this, p_bank, path, i_maxdepth - 1);
else else
if (S_ISREG (st.st_mode) if (S_ISREG (st.st_mode)
&& ((size_t)pathlen >= strlen (LIBEXT)) && strncmp (path, "lib", 3)
&& !strncasecmp (path + pathlen - strlen (LIBEXT), LIBEXT, && ((size_t)pathlen >= sizeof ("_plugin"LIBEXT))
strlen (LIBEXT))) && !strncasecmp (path + pathlen - strlen ("_plugin"LIBEXT),
/* ^^ We only load files ending with LIBEXT */ "_plugin"LIBEXT, strlen ("_plugni"LIBEXT)))
/* ^^ We only load files matching "lib*_plugin"LIBEXT */
AllocatePluginFile (p_this, p_bank, path, st.st_mtime, st.st_size); AllocatePluginFile (p_this, p_bank, path, st.st_mtime, st.st_size);
free (path); free (path);
......
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