rendered paste bodyvoid findFile(std::vector<std::string>& fileList, const std::string& path){ HANDLE hSearch; WIN32_FIND_DATA findData; std::string findPath; std::string fileName; hSearch = FindFirstFile((path + "\\*").c_str(), &findData); if (hSearch == INVALID_HANDLE_VALUE) { std::cerr << "ファイルの検索に失敗しました" << std::endl; return; } do { fileName = std::string(findData.cFileName); if (fileName != "." && fileName != "..") { if (findData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) { findFile(fileList, path + "\\" + fileName); }else{ fileList.push_back(path + "\\" + fileName); } } } while (FindNextFile(hSearch, &findData)); FindClose(hSearch);}