* Fix forbiden windows characters list. (in fact it's not windows only, but fat32...
authorAntoine Cellerier <dionoea@videolan.org>
Thu, 1 Mar 2007 22:44:16 +0000 (22:44 +0000)
committerAntoine Cellerier <dionoea@videolan.org>
Thu, 1 Mar 2007 22:44:16 +0000 (22:44 +0000)
src/text/strings.c

index b686b3d..0f70734 100644 (file)
@@ -804,15 +804,14 @@ void filename_sanitize( char *str )
         {
             case '/':
 #ifdef WIN32
+            case '\\':
             case '*':
             case '"':
-            case '\\':
-            case '[':
-            case ']':
+            case "?":
             case ':':
-            case ';':
             case '|':
-            case '=':
+            case '<':
+            case '>'
 #endif
                 *str = '_';
         }
@@ -825,22 +824,21 @@ void filename_sanitize( char *str )
  */
 void path_sanitize( char *str )
 {
+#ifdef WIN32
     while( *str )
     {
         switch( *str )
         {
-#ifdef WIN32
             case '*':
             case '"':
-            case '[':
-            case ']':
+            case "?":
             case ':':
-            case ';':
             case '|':
-            case '=':
-#endif
+            case '<':
+            case '>'
                 *str = '_';
         }
         str++;
     }
+#endif
 }