use S_ISREG to check is a regular file?

This commit is contained in:
halx99 2019-11-27 15:41:30 +08:00
parent 4a040efbf6
commit 02c18d656a
1 changed files with 1 additions and 1 deletions

View File

@ -194,7 +194,7 @@ bool FileUtilsAndroid::isFileExistInternal(const std::string& strFilePath) const
{
struct stat64 st;
if (0 == ::stat64(strFilePath.c_str(), &st))
bFound = st.st_mode & S_IFREG;
bFound = S_ISREG(st.st_mode);
}
return bFound;
}