瀏覽代碼

REVIEWED: `ScanDirectoryFiles*()`- Paths building slashes sides #3507

pull/3512/head
Ray 1 年之前
父節點
當前提交
8b2103fc77
共有 1 個檔案被更改,包括 8 行新增0 行删除
  1. +8
    -0
      src/rcore.c

+ 8
- 0
src/rcore.c 查看文件

@ -3173,7 +3173,11 @@ static void ScanDirectoryFiles(const char *basePath, FilePathList *files, const
if ((strcmp(dp->d_name, ".") != 0) &&
(strcmp(dp->d_name, "..") != 0))
{
#if defined(_WIN32)
sprintf(path, "%s\\%s", basePath, dp->d_name);
#else
sprintf(path, "%s/%s", basePath, dp->d_name);
#endif
if (filter != NULL)
{
@ -3212,7 +3216,11 @@ static void ScanDirectoryFilesRecursively(const char *basePath, FilePathList *fi
if ((strcmp(dp->d_name, ".") != 0) && (strcmp(dp->d_name, "..") != 0))
{
// Construct new path from our base path
#if defined(_WIN32)
sprintf(path, "%s\\%s", basePath, dp->d_name);
#else
sprintf(path, "%s/%s", basePath, dp->d_name);
#endif
if (IsPathFile(path))
{

Loading…
取消
儲存