Lines Matching refs:dirp
848 int closedir(DIR *dirp) in closedir() argument
850 if (dirp != NULL && dirp->find_handle != INVALID_HANDLE_VALUE) in closedir()
851 FindClose(dirp->find_handle); in closedir()
853 free(dirp); in closedir()
857 struct dirent *readdir(DIR *dirp) in readdir() argument
862 if (dirp == NULL) in readdir()
865 if (dirp->find_handle == INVALID_HANDLE_VALUE) { in readdir()
867 StringCchPrintfA(search_pattern, MAX_PATH, "%s\\*", dirp->dirname); in readdir()
868 dirp->find_handle = FindFirstFileA(search_pattern, &find_data); in readdir()
869 if (dirp->find_handle == INVALID_HANDLE_VALUE) in readdir()
872 if (!FindNextFile(dirp->find_handle, &find_data)) in readdir()