瀏覽代碼

Fix SDL_GlobDirectory

Alexander Batalov 9 月之前
父節點
當前提交
2b784b5bf6
共有 1 個文件被更改,包括 6 次插入0 次删除
  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.