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

file: Be consistent with the rest of the world. Do not expand tilde.

The shell already does it, and \~ should not be expanded by VLC.
Also fixes consistency with the other file-opening plugins
(directory, mmap, cdda...).
Signed-off-by: default avatarRémi Denis-Courmont <rem@videolan.org>
parent 73e7165f
...@@ -380,16 +380,6 @@ static int Control( access_t *p_access, int i_query, va_list args ) ...@@ -380,16 +380,6 @@ static int Control( access_t *p_access, int i_query, va_list args )
static char *expand_path (const access_t *p_access, const char *path) static char *expand_path (const access_t *p_access, const char *path)
{ {
if (strncmp (path, "~/", 2) == 0)
{
char *res;
// TODO: we should also support the ~cmassiot/ syntax
if (asprintf (&res, "%s/%s", p_access->p_libvlc->psz_homedir, path + 2) == -1)
return NULL;
return res;
}
#if defined(WIN32) #if defined(WIN32)
if (!strcasecmp (p_access->psz_access, "file") if (!strcasecmp (p_access->psz_access, "file")
&& ('/' == path[0]) && path[1] && (':' == path[2]) && ('/' == path[3])) && ('/' == path[0]) && path[1] && (':' == path[2]) && ('/' == path[3]))
......
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