30 struct _finddata_t info;
41 size_t base_length = strlen(name);
43 strchr(
"/\\", name[base_length - 1]) ?
"*" :
"/*";
45 if((dir = (
DIR *)
malloc(
sizeof *dir)) != 0 &&
46 (dir->
name = (
char *)
malloc(base_length + strlen(all) + 1)) != 0)
48 strcat(strcpy(dir->
name, name), all);
84 result = _findclose(dir->
handle);
103 if(dir && dir->
handle != -1)
121 if(dir && dir->
handle != -1)
SWDLLEXPORT void rewinddir(DIR *dir)
SWDLLEXPORT DIR * opendir(const char *name)
SWDLLEXPORT struct dirent * readdir(DIR *dir)
SWDLLEXPORT int closedir(DIR *dir)