]> git.sesse.net Git - vlc/commitdiff
Removes useless sanity checks
authorRafaël Carré <funman@videolan.org>
Wed, 1 Nov 2006 08:17:42 +0000 (08:17 +0000)
committerRafaël Carré <funman@videolan.org>
Wed, 1 Nov 2006 08:17:42 +0000 (08:17 +0000)
modules/access/file.c

index cd8d2e943af7a4d8e87ab2cac1ca5cb384f11292..856e8180da07ee8f554b0b9cdee0870d74ac9e59 100644 (file)
@@ -508,7 +508,7 @@ 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)
 {
-    if ( ( strlen (path) >= 2 ) && ( strncmp (path, "~/", 2) == 0 ))
+    if (strncmp (path, "~/", 2) == 0)
     {
         char *res;
 
@@ -519,8 +519,7 @@ static char *expand_path (const access_t *p_access, const char *path)
     }
 
 #if defined(WIN32)
-    if ( ( strlen(p_access->psz_access ) >= 4 )
-      && !strcasecmp (p_access->psz_access, "file")
+    if (!strcasecmp (p_access->psz_access, "file")
       && ('/' == path[0]) && path[1] && (':' == path[2]) && ('/' == path[3]))
         // Explorer can open path such as file:/C:/ or file:///C:/
         // hence remove leading / if found