]> git.sesse.net Git - vlc/commitdiff
Access: remove special case for "-" (standard input)
authorRémi Denis-Courmont <remi@remlab.net>
Sat, 16 Jan 2010 15:44:07 +0000 (17:44 +0200)
committerRémi Denis-Courmont <remi@remlab.net>
Sat, 16 Jan 2010 15:45:28 +0000 (17:45 +0200)
"-" is now converted to "fd://0" by the input code. And file:///- really
means /- (which is a valid file name).

modules/access/dvdnav.c
modules/access/file.c
modules/access/mmap.c

index 3fb79f246a0de00a29721ec1b77f50de8edaaa9b..82dedfb68b7e3178c0ead81e93e37436e22c8b2b 100644 (file)
@@ -1367,9 +1367,6 @@ static int ProbeDVD( demux_t *p_demux, char *psz_name )
         return VLC_SUCCESS;
     }
 
-    if( !strcmp( psz_name, "-" ) ) /* stdin -> file access */
-        return VLC_EGENERIC;
-
     if( (i_fd = utf8_open( psz_name, O_RDONLY |O_NONBLOCK )) == -1 )
     {
         return VLC_SUCCESS; /* Let dvdnav_open() do the probing */
index de42c39d0dfdaee937f4d7ac473e9b1cfaf69d36..bd166c760c13b8b59a48c49713ab8069ae709f57 100644 (file)
@@ -140,8 +140,6 @@ int Open( vlc_object_t *p_this )
 
     if (!strcasecmp (p_access->psz_access, "fd"))
         fd = dup (atoi (path));
-    else if (!strcmp (path, "-"))
-        fd = dup (0);
     else
     {
         msg_Dbg (p_access, "opening file `%s'", path);
index 06092420c84af4c68ff2b8e46c2493c56fa4421a..2bad6f2860a7accce4927247f7b4b3e451428669 100644 (file)
@@ -93,13 +93,8 @@ static int Open (vlc_object_t *p_this)
 
     STANDARD_BLOCK_ACCESS_INIT;
 
-    if (!strcmp (p_access->psz_path, "-"))
-        fd = dup (0);
-    else
-    {
-        msg_Dbg (p_access, "opening file %s", path);
-        fd = utf8_open (path, O_RDONLY | O_NOCTTY);
-    }
+    msg_Dbg (p_access, "opening file %s", path);
+    fd = utf8_open (path, O_RDONLY | O_NOCTTY);
 
     if (fd == -1)
     {