Changeset 364 in Main for trunk/Common/dir.c


Ignore:
Timestamp:
Oct 17, 2024, 9:47:01 AM (4 weeks ago)
Author:
Nishi
Message:

fix path stuff

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Common/dir.c

    r315 r364  
    7070        return r;
    7171#else
    72         DIR* dir = opendir(path);
     72        char* fxpath = cm_strcat(path, "/");
     73        DIR* dir = opendir(fxpath);
    7374        if(dir != NULL) {
    7475                char** r = malloc(sizeof(*r));
     
    109110
    110111                closedir(dir);
     112                free(fxpath);
    111113
    112114                return r;
    113115        } else {
     116                free(fxpath);
    114117                return NULL;
    115118        }
Note: See TracChangeset for help on using the changeset viewer.