Procházet zdrojové kódy

Fix SDL_GlobDirectory

Alexander Batalov před 1 rokem
rodič
revize
2b784b5bf6
1 změnil soubory, kde provedl 6 přidání a 0 odebrání
  1. 6 0
      src/filesystem/SDL_filesystem.c

+ 6 - 0
src/filesystem/SDL_filesystem.c

@@ -188,6 +188,12 @@ static bool WildcardMatch(const char *pattern, const char *str, bool *matched_to
             sch = *str;
             pch = *pattern;
         }
+
+#if defined(SDL_PLATFORM_WINDOWS)
+        if (sch == '\\') {
+            sch = '/';
+        }
+#endif
     }
 
     // '*' at the end can be ignored, they are allowed to match nothing.