提交 243d5992 编写于 作者: H HexToString

support 3 types para

上级 69338f1c
......@@ -81,15 +81,10 @@ const std::string& getFileBySuffix(
while ((dirp = readdir(dp)) != nullptr) {
if (dirp->d_type == DT_REG) {
for (int idx = 0; idx < suffixVector.size(); ++idx) {
if (suffixVector[idx].compare("*") == 0) {
if (std::string(dirp->d_name).find(suffixVector[idx]) !=
std::string::npos) {
fileName = static_cast<std::string>(dirp->d_name);
break;
} else {
if (std::string(dirp->d_name).find(suffixVector[idx]) !=
std::string::npos) {
fileName = static_cast<std::string>(dirp->d_name);
break;
}
}
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册