1
0
mirror of https://github.com/facebook/zstd.git synced 2025-07-30 22:23:13 +03:00

Introduce Dedicated Helper to Call stat()

This commit is contained in:
W. Felix Handte
2020-08-05 00:09:29 -04:00
parent 38e38546a4
commit b11bea56a5
2 changed files with 18 additions and 0 deletions

View File

@ -99,6 +99,17 @@ int g_utilDisplayLevel;
* Functions
***************************************/
int UTIL_stat(const char* filename, stat_t* statbuf)
{
#if defined(_MSC_VER)
return !_stat64(filename, statbuf);
#elif defined(__MINGW32__) && defined (__MSVCRT__)
return !_stati64(filename, statbuf);
#else
return !stat(filename, statbuf);
#endif
}
int UTIL_fileExist(const char* filename)
{
stat_t statbuf;