aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2015-12-08 19:39:50 -0800
committerChris Robinson <[email protected]>2015-12-08 19:43:00 -0800
commit26f8676b9b420390f4cd2cb9121dffbaeeabb918 (patch)
treebcab257ac8708b7d4a66b93d9cdc37108ccf4e35
parentf8a4ef6f514ad0accfc4fb7a05506f1879798b81 (diff)
Fix slashes on the local path on Windows
-rw-r--r--Alc/helpers.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/Alc/helpers.c b/Alc/helpers.c
index 3e8d9972..e9efddf3 100644
--- a/Alc/helpers.c
+++ b/Alc/helpers.c
@@ -866,6 +866,9 @@ vector_al_string SearchDataFiles(const char *match, const char *subdir)
}
free(cwdbuf);
}
+#define FIX_SLASH(i) do { if(*(i) == '/') *(i) = '\\'; } while(0)
+ VECTOR_FOR_EACH(char, path, FIX_SLASH);
+#undef FIX_SLASH
RecurseDirectorySearch(al_string_get_cstr(path), wmatch, &results);
/* Search the local and global data dirs. */