diff options
Diffstat (limited to 'Source/Core/Common/FileSearch.cpp')
| -rw-r--r-- | Source/Core/Common/FileSearch.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Source/Core/Common/FileSearch.cpp b/Source/Core/Common/FileSearch.cpp index 13e99fe88a..b5395cf21c 100644 --- a/Source/Core/Common/FileSearch.cpp +++ b/Source/Core/Common/FileSearch.cpp @@ -28,7 +28,8 @@ static std::vector<std::string> FileSearchWithTest(const std::vector<std::string for (auto& child : entry.children) DoEntry(child); }; - DoEntry(top); + for (auto& child : top.children) + DoEntry(child); } // remove duplicates std::sort(result.begin(), result.end()); @@ -53,6 +54,7 @@ std::vector<std::string> DoFileSearch(const std::vector<std::string>& globs, con }); } +// Result includes the passed directories themselves as well as their subdirectories. std::vector<std::string> FindSubdirectories(const std::vector<std::string>& directories, bool recursive) { return FileSearchWithTest(directories, true, [&](const File::FSTEntry& entry) { |
